Pushing a new branch (protected via wildcard) fails after upgrade from GitLab omnibus 11.8.3 to 11.9.0 (note: owner is trying to push and wildcard allows push to maintainers)
Scenario:
- GitLab repo has a wildcard for a branch protection (with 'Allowed to push' value set to 'Maintainers')
- owner user creates a new branch (branch name matches wildcard)
- owner tries to push that branch into a git repo using git bash console
- error message (after failed push) appears:
'remote: GitLab: You can only create protected branches using the web interface and API.'
See attached snapshot also.
Related link: https://docs.gitlab.com/11.9/ce/user/project/protected_branches.html#creating-a-protected-branch
When a protected branch or wildcard protected branches are set to No one is Allowed to push, Developers (and users with higher permission levels) are allowed to create a new protected branch, but only via the UI or through the API (to avoid creating protected branches accidentally from the command line or from a Git client application).
Environment:
sudo gitlab-rake gitlab:env:info
System information
System:
Current User: git
Using RVM: no
Ruby Version: 2.5.3p105
Gem Version: 2.7.6
Bundler Version:1.16.6
Rake Version: 12.3.2
Redis Version: 3.2.12
Git Version: 2.18.1
Sidekiq Version:5.2.5
Go Version: unknown
GitLab information
Version: 11.9.0
Revision: a47124c
Directory: /opt/gitlab/embedded/service/gitlab-rails
DB Adapter: postgresql
URL: https://**************
HTTP Clone URL: https://*********************
SSH Clone URL: git@*************************
Using LDAP: no
Using Omniauth: yes
Omniauth Providers:
GitLab Shell
Version: 8.7.1
Repository storage paths:
- default: /var/opt/gitlab/git-data/repositories
GitLab Shell path: /opt/gitlab/embedded/service/gitlab-shell
Git: /opt/gitlab/embedded/bin/git