table of contents
| PKGOS-SALSA-SET-WEBHOOK(1) | Debian OpenStack packaging | PKGOS-SALSA-SET-WEBHOOK(1) |
NAME¶
pkgos-salsa-set-webhook - add a Jenkins build-on-push webhook to a project of the Debian OpenStack team
SYNOPSIS¶
pkgos-salsa-set-webhook --openstack-release <release> --debian-release <suite> --project-name <name> [--project-id <id>] [--jenkins-token <token>] [--debug]
DESCRIPTION¶
pkgos-salsa-set-webhook adds a push webhook to a project of the Debian OpenStack team on salsa.debian.org, so that any push on the debian/<new-release> branch triggers a build on the Jenkins instance at https://<debian-release>-<new-release>.debian.net. Exactly one of --project-name and --project-id must be given; the project name is resolved to its numeric ID through pkgos-salsa-get-project-id(1).
If the project's default branch on the GitLab side isn't named debian/<release> (for example if it is "master", like for projects not following the debian/<openstack-release> branch schema), the webhook is created without a push_events_branch_filter, with branch_filter_strategy set to all_branches, so that the GitLab UI shows it as triggering on All branches, and that pushes to any branch trigger Jenkins. In that case, --openstack-release is still needed to know which Jenkins instance to use. This is decided by a read-only GET on the project, which is also performed with --debug.
OPTIONS¶
- --openstack-release <release>
- Name of the OpenStack release, for example "flamingo". Also used as the push_events_branch_filter of the webhook (ie: the debian/<new-release> branch). If omitted, it defaults to the OpenStack release of the currently checked-out debian/<release> Git branch, provided that release is listed in /etc/pkgos/openstack-release.txt.
- --debian-release <suite>
- Debian release name for which the Jenkins instance is named, for example "trixie". If omitted, it is guessed from --openstack-release using /etc/pkgos/openstack-debian-release.txt, when that release is available on exactly one Debian release; when it is available on several (eg: zed), the script refuses to guess and --debian-release must be passed explicitly.
- --project-name <name>
- Name of the project, for example "nova". If omitted, it defaults to the name of the Git repository containing the current working directory (ie: the basename of the toplevel directory), when running from inside a Git repository. A --project-name passed on the command line always takes precedence.
- --project-id <id>
- Numeric ID of the project, as optional alternative to --project-name.
- --jenkins-token <token>
- Authentication token of the Jenkins instance.
- --debug
- Print the URL that would be posted, but do not perform the API call.
ENVIRONMENT¶
- SALSA_TOKEN
- Salsa personal access token with API access. May also be set in /etc/pkgos/pkgos.conf.
EXAMPLES¶
- pkgos-salsa-run-on-all-projects pkgos-salsa-set-webhook \
- --openstack-release grizzly --debian-release forky --jenkins-token <token>
SEE ALSO¶
pkgos-salsa-get-project-id(1), pkgos-salsa-run-on-all-projects(1), pkgos-salsa-edit-webhook(1), pkgos-salsa-new-openstack-release(1).
AUTHOR¶
This script and its man page: (c) 2026, Thomas Goirand <zigo@debian.org>, released under the Apache-2.0 license.
| 23 September 2026 | openstack-pkg-tools |