Protect Your Pipeline: Restrict Who Can Start It Manually or Edit Its Configuration
If you want to prevent unauthorized users from manually starting your pipeline or editing (and changing) its configuration, you can impose those restrictions from the Pipeline Protection tab on the Project Administration Builds page:
When a pipeline is protected, the Pipeline Details page won't show the
Configure and Delete buttons to
unauthorized users for protected pipelines and the Configure
Pipeline option in the Actions
menu on the Pipelines page won't be available. However, an unauthorized
user could still inadvertently access a protected pipeline, perhaps by using a
bookmarked URL that was saved before the user lost access, and this is what they'll
see:
Description of the illustration pipeline-protection-error.png
The lock icon in the Private column in the list of pipelines on the
Pipelines page identifies protected pipelines.
The project's activity feed shows all edit-restricting activities, thereby providing a historical record of showing how the pipeline was protected. The pipeline log also records these protective activities and provides a historical accounting that can be referred to later, if needed.
Tip:
Protecting the pipeline prevents unauthorized users from editing the configuration but it does not prevent anyone from running the pipeline. The only way to limit that is to protect the initial job (the one that follows the Start node) by changing its Job Protection Settings to Private. That way, if the job is triggered in a pipeline by an unauthorized user or group, it won't be initiated. By default, the Job Protection settings don't allow commits and triggers to start a private job. You may, however, click the Allow commits and triggers to start this private job button to allow the job to be initiated if it is triggered by an SCM commit or by a timer. See Configure Job Protection Settings for more information.