CI/CD AWS_ variable validation regression
Summary
We have been setting variables at the group level to use as values for AWS_ACCESS_KEY_ID
and AWS_SECRET_ACCESS_KEY
on the project level.
!29959 (closed) broke this functionality.
Steps to reproduce
Group CI/CD Variables
Type | Key | Value | Protected | Masked |
---|---|---|---|---|
Var | PROD_ACCESS_KEY_ID |
... |
||
Var | PROD_SECRET_ACCESS_KEY |
... |
Project CI/CD Variables
Type | Key | Value | Protected | Masked | Environments |
---|---|---|---|---|---|
Var | AWS_ACCESS_KEY_ID |
$PROD_ACCESS_KEY_ID |
production | ||
Var | AWS_SECRET_ACCESS_KEY |
$PROD_SECRET_ACCESS_KEY |
production |
What is the current bug behavior?
The following error message is shown, and the Add/Update Variable button is disabled.
This variable does not match the expected pattern.
What is the expected correct behavior?
Group-level variables should be allowed values for AWS_ACCESS_KEY_ID
and AWS_SECRET_ACCESS_KEY
at the project level.
Results of GitLab environment info
Expand for output related to GitLab environment info
System information System: Debian 9.2 Proxy: no Current User: git Using RVM: no Ruby Version: 2.6.5p114 Gem Version: 2.7.10 Bundler Version:1.17.3 Rake Version: 12.3.3 Redis Version: 5.0.7 Git Version: 2.26.2 Sidekiq Version:5.2.7 Go Version: unknown GitLab information Version: 12.10.1-ee Revision: 695c29abcf7 Directory: /opt/gitlab/embedded/service/gitlab-rails DB Adapter: PostgreSQL DB Version: 10.9 URL: https://gitlab. HTTP Clone URL: https://gitlab./some-group/some-project.git SSH Clone URL: git@gitlab.:some-group/some-project.git Elasticsearch: yes Geo: no Using LDAP: no Using Omniauth: yes Omniauth Providers: saml GitLab Shell Version: 12.2.0 Repository storage paths: - default: /opt/gitlab/git-data/repositories GitLab Shell path: /opt/gitlab/embedded/service/gitlab-shell Git: /opt/gitlab/embedded/bin/git
Results of GitLab application Check
Expand for output related to the GitLab application check
Checking GitLab subtasks ...Checking GitLab Shell ...
GitLab Shell: ... GitLab Shell version >= 12.2.0 ? ... OK (12.2.0) Running /opt/gitlab/embedded/service/gitlab-shell/bin/check Internal API available: OK Redis available via internal API: OK gitlab-shell self-check successful
Checking GitLab Shell ... Finished
Checking Gitaly ...
Gitaly: ... default ... OK
Checking Gitaly ... Finished
Checking Sidekiq ...
Sidekiq: ... Running? ... yes Number of Sidekiq processes ... 2 Try fixing it: sudo service gitlab stop sudo pkill -u git -f sidekiq sleep 10 && sudo pkill -9 -u git -f sidekiq sudo service gitlab start Please fix the error above and rerun the checks.
Checking Sidekiq ... Finished
Checking Incoming Email ...
Incoming Email: ... Reply by email is disabled in config/gitlab.yml
Checking Incoming Email ... Finished
Checking LDAP ...
LDAP: ... LDAP is disabled in config/gitlab.yml
Checking LDAP ... Finished
Checking GitLab App ...
Git configured correctly? ... yes Database config exists? ... yes All migrations up? ... yes Database contains orphaned GroupMembers? ... no GitLab config exists? ... yes GitLab config up to date? ... yes Log directory writable? ... yes Tmp directory writable? ... yes Uploads directory exists? ... yes Uploads directory has correct permissions? ... yes Uploads directory tmp has correct permissions? ... yes Init script exists? ... skipped (omnibus-gitlab has no init script) Init script up-to-date? ... skipped (omnibus-gitlab has no init script) Projects have namespace: ... Redis version >= 4.0.0? ... yes Ruby version >= 2.5.3 ? ... yes (2.6.5) Git version >= 2.22.0 ? ... yes (2.26.2) Git user has default SSH configuration? ... yes Active users: ... 742 Is authorized keys file accessible? ... yes Elasticsearch version 5.6 - 6.x? ... yes (7.4.2)
Checking GitLab App ... Finished
Checking GitLab subtasks ... Finished
Possible fixes
Revert or amend !29959 (closed).