Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Tag restriction

Kajsa November 8, 2021

I would like to restrict who can add git-tags to the bitbucket cloud repository, so that only certain users can start tag triggered pipelines. Ideally, I would like to set a permission so that only a specified list of users can tag with specific formats, only annotated tags are allowed, any other tag attempts are rejected.

I've looked at branch pattern permissions for `refs/tags/**` and server-side hooks, neither of which seem to be supported by Bitbucket Cloud.

E.g.

General user can add annotated tag `hello-world`.
General user can not add lightweight tag `hello-world`, tag is rejected.
General user can not add annotated tag `pipeline-trigger-<number>`, tag is rejected.
Admin user can add annotated tag `pipeline-trigger-<number>` which triggers a specific pipeline.
Admin user can add annotated tag `hello-world`.
Admin user can not add lightweight tag `hello-world`, tag is rejected.

1 answer

0 votes
Caroline R
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
November 9, 2021

Hi, @Kajsa

Thank you for reaching out to Atlassian Community!

I'm afraid Bitbucket Cloud doesn't have a feature for tag restriction at the moment (we only have the branch permission - restriction feature where you can restrict branches, but not tags).

We do have an existing feature request to restrict pushing Git tags to certain users in a Bitbucket Repository: 

I would suggest that you add your vote there (by selecting the Vote for this issue link) as the number of votes helps the development team and product managers better understand the demand for new features. 

You are more than welcome to leave any feedback, and you can also add yourself as a watcher (by selecting the Start watching this issue link) if you'd like to get notified via email on updates (all future updates will be shared on that ticket).

Implementation of new features is done as per our policy here and any updates will be posted in the feature request. 

Kind regards,
Caroline

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events