Docker:
At least 25GB of free disk space.
Your username in the “docker” group.
Follow the instructions on Ask Ubuntu.
Gcloud:
You may need to authenticate and set the current project. To do so, run:
gcloud auth login gcloud config set project bazel-public gcloud config set zone europe-west1-d
The process typically looks like:
Make your change.
Deploy to production with bazel run //gcr:deploy
.
Gracefully restart the Jenkins instance: https://ci.bazel.build/safeExit
If Jenkins doesn't exit fast enough, ensure that no important jobs are running and then: https://ci.bazel.build/exit
You can run a local Jenkins instance with a Docker executor node, by running:
bazel run //jenkins/test [-- -p port]
It will spin up a Jenkins instance:
port
(8080 by default)This setup should suffice for local testing.
To stop the instance, go to http://localhost:8080/exit
. This will shut down Jenkins cleanly.
You can connect additional instance by modifying the UI to test for other platforms. However this does not enable to test:
If you only need to modify Groovy code under jenkins/lib
, you can update that in the running container without restarting Jenkins.
Start the container:
bazel run //jenkins/test
Make your changes to .groovy
files.
Transfer the lib
folder to the running container:
jenkins/transfer-lib.sh