commit message from python script

This commit is contained in:
2023-05-03 20:00:02 +02:00
parent f35f1a86ac
commit b42b7c3869
4 changed files with 60 additions and 2 deletions

View File

@@ -0,0 +1,15 @@
import jenkins
jenkins_client = jenkins.Jenkins('https://man-dan-03:9443', username='JonnyBravo', password='113c3449636622439627ab1d51454fc07c')
# Get all builds
all_jobs = jenkins_client.get_all_jobs()
# Show Job Infos
job_info = jenkins_client.get_job_info(name='test_4')
print(job_info)
# Show Job Name
for job_line in all_jobs:
print(job_line['name'])
# start Job
job_start = jenkins_client.build_job(name='test_4', parameters={'test' : 'test_python'})