Jenkins + Docker + Python
This is going to be a very brief tutorialish article, nothing too fancy or complicated. You’re going to need Docker for this, and the installation instructions are over here for Ubuntu https://docs.docker.com/engine/installation/linux/ubuntulinux/
Once you have Docker setup you just need the official Jenkins docker image from over here https://hub.docker.com/_/jenkins/
docker pull jenkins
docker run -p 8080:8080 -p 50000:50000 jenkins
You can now access Jenkins at localhost:8080
We need to install the git plugin next, in the dashboard page on the left click Manage Jenkins -> Manage Plugins -> Available and install Git plugin and from the list.
After that let’s create a new job from the dashboard. Give it a name and pick Freestyle project.
At the Source Code Management section, type in the repo’s url and add your credentials.
python -m unittest discover -v
If you click Console on the left, you can can see that the tests have run successfully.