Very Simple Jenkins Job Calling Python Script

Job ID: 36574531

Budget: £18 – £36 GBP

This is a small piece of work as a proof of concept.
You must have your own Jenkins and GitHub setup.
You can makeup your own files and folder structure


Step 1) Pass 4 parameters to a Jenkins job - This job will be called by ServiceNow & Salesforce
The four parameters are ProductName, ApplicationName, JiraDb, TargetURL
I'm guessing the special characters in a url could be a pain

Step 2) The Jenkins job will run a python script with the 4 parameters

Step 3) The python script will mirror/copy an existing GitHub Repository.
The script will use the ProductName parameter for the new repo [ProductName.git]

Step 4) The new mirrored repo should already have folders and config files in it.
The python script now has to edit one of the config files and change some values.
Let's assume the file is called Config.YAML in a folder called API
The python script wil locate the ProductName, ApplicationName & TargetUrl Nodes and change them to the new values.
You can assume the structure of this file is known.

Step 5) Create an encrypted key (this is a demo not a real oAuth2 key) using the ProductName & ApplicationName

Step 6) Place that new encrypted "key" in the key folder in the new Git repo.

That's It!
Related categories: Python Jenkins