The environment parameter

The environment parameter is used to specify a particular environment to which a job will be deployed. Environments are discussed in the Environments section later in this chapter. The environment key can contain multiple other keys, most commonly name and url. The name sub-key defines a name for an environment to which the code will be deployed. You can track this using the GitLab web user interface by going to Project | Operations | Environments. While you can create new environments in the web user interface, it's recommended that you define them first in the .gitlab-ci.yml file, which will automatically create them in the web UI on its first run. The url parameter will be exposed in multiple parts of the GitLab ...

Get GitLab Quick Start Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.