example k8s pipeline
This commit is contained in:
parent
82ba3bc778
commit
6fef7854ac
4 changed files with 113 additions and 0 deletions
14
python-jobs/pipeline.py
Normal file
14
python-jobs/pipeline.py
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
import time
|
||||
import logging
|
||||
|
||||
logger = logging.getLogger()
|
||||
logger.setLevel(logging.INFO)
|
||||
logger.addHandler(logging.StreamHandler())
|
||||
|
||||
# log to ./log.log
|
||||
logger.addHandler(logging.FileHandler("./log.log"))
|
||||
|
||||
for node in range(120):
|
||||
print(f"running {node+1} of 120")
|
||||
time.sleep(5)
|
||||
logger.info(f"done {node}")
|
||||
Loading…
Add table
Add a link
Reference in a new issue