Difference between revisions of "GitLab environments"
Jump to navigation
Jump to search
Line 4: | Line 4: | ||
* <code>[[environment:]]</code> | * <code>[[environment:]]</code> | ||
+ | |||
+ | == Dynamic environment official example == | ||
+ | |||
+ | deploy_review: | ||
+ | stage: deploy | ||
+ | script: | ||
+ | - echo "Deploy a review app" | ||
+ | environment: | ||
+ | name: review/$CI_COMMIT_REF_SLUG | ||
+ | url: https://$CI_ENVIRONMENT_SLUG.example.com | ||
+ | rules: | ||
+ | - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH | ||
+ | when: never | ||
+ | - if: $CI_COMMIT_BRANCH | ||
+ | |||
== Related == | == Related == |
Revision as of 10:58, 29 July 2022
Dynamic environment official example
deploy_review: stage: deploy script: - echo "Deploy a review app" environment: name: review/$CI_COMMIT_REF_SLUG url: https://$CI_ENVIRONMENT_SLUG.example.com rules: - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH when: never - if: $CI_COMMIT_BRANCH
Related
See also
- GitLab: Install GitLab, Upgrade GitLab Gitlab runner (changelog),
gitlab.rb, .gitlab/, gitlab-ci.yml
,gitlab-ctl, gitlab-rake, gitlab-backup, gitlab-rails
, GitLab editions, GitLab Security Dashboards, GitLab environments, GitLab environment variables, Auto DevOps, permissions, GitLab Pages,gitlab-rails
, GitLab scheduled pipelines, GitLab logs, GitLab changelog , GitLab Release CLI, GitLab Omnibus, GitLab Advanced Search, GitLab container registry, GitLab infrastructure registry
Advertising: