Collection of CI workflows for python repos.
- pytest for automated testing on pull request
- ruff for linting
- mypy for typechecking
All of these run in docker containers which are built based on changes to the Dockerfile or pyproject.toml.
Every workflow begins with checking if the appropriate image already exists on the registry and if it doesn't it's built and uploaded. This makes it robust to deleting unused images on your registry since they are rebuilt as needed. Currently uses quay.io for storing images since it's free if the images are public.
- Create a new git repo. I'll refer to its name as
<name of your repo>and to its URL as<repo URL> git clone https://github.com/tobsecret/CI.git && mv CI <name of your repo> && cd <name of your new repo> && mv CI <name of your repo>rm -rf .git && git init -b maingit remote add origin <repo URL> && git push -u origin main- Create a
quay.ioaccount and password, and a quay organization - Set up the following variables and secrets on your repo
- Variables
- QUAY_ORG
- Secrets
- QUAY_USER
- QUAY_PASSWORD
- Variables
- fast CLI setup with cookiecutter template
- setup that can use org variables rather than repo variables so you can set up org variables once and be set
- image guide for setting up the github variables and the quay.io account