diff options
author | Devan Carpenter <devan@taler.net> | 2023-12-17 19:40:47 -0500 |
---|---|---|
committer | Devan Carpenter <devan@taler.net> | 2023-12-17 19:41:31 -0500 |
commit | ac94943039f6cd70cd19b03846f5019d2eecc152 (patch) | |
tree | fa52459632e233494243a6eba3eb01b5edd41125 /design-documents | |
parent | 57a78d71ab7a4bd774bdf7f8509710dc498b4c98 (diff) | |
download | docs-ac94943039f6cd70cd19b03846f5019d2eecc152.tar.gz docs-ac94943039f6cd70cd19b03846f5019d2eecc152.tar.bz2 docs-ac94943039f6cd70cd19b03846f5019d2eecc152.zip |
DD44: document using script to run jobs local
Diffstat (limited to 'design-documents')
-rw-r--r-- | design-documents/044-ci-system.rst | 38 |
1 files changed, 23 insertions, 15 deletions
diff --git a/design-documents/044-ci-system.rst b/design-documents/044-ci-system.rst index 78d64830..cfb733aa 100644 --- a/design-documents/044-ci-system.rst +++ b/design-documents/044-ci-system.rst @@ -94,24 +94,32 @@ Running CI Locally Running the CI scripts locally can be useful for development and testing. -*Be aware that custom configs for a given job may specify a alternate -container.* - - -Example of building the environment and running a job locally: +Included in each CI directory is a script which simplifies running jobs +in the same way the CI Worker does, in containers, using either `podman` +or `docker`, detecting if you have either installed. :: - # From root of repo directory, build the container: - docker build -t <local_name_for_container> -f ci/Containerfile . # <- don't forget the "." - - # Then to run one of the job scripts. For example: - docker run --rm --volume $PWD:/workdir --workdir /workdir <local_name_for_container> ci/jobs/1-build/job.sh - - # or to get an interactive shell in the container, with the repo mounted at /workdir: - docker run -ti --rm --volume $PWD:/workdir --workdir /workdir <local_name_for_container> /bin/bash - - + # Usage: + ./contrib/ci/ci.sh <job-name> + + # For example, if the CI jobs tree looks like this: + ./contrib/ci/jobs + ├── 0-codespell/ + ├── 1-build/ + ├── 2-test/ + ├── 3-docs/ + ├── 4-deb-package/ + └── 5-deploy-package/ + + # Then you can run job '0-codespell' as follows: + ./contrib/ci/ci.sh 0-codespell + + # If you are using podman and have "qemu-user-binfmt" installed + # then you may attempt to run any job under an alternative CPU + # architecture by providing a second argument. + # For example: + ./contrib/ci/ci.sh 0-codespell arm64 Additional Builders |