Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
ac60dfc6
Commit
ac60dfc6
authored
Jun 24, 2020
by
Suzanne Selhorn
Committed by
Marcel Amirault
Jun 24, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Docs: dotenv post-merge review
Related to:
https://gitlab.com/gitlab-org/gitlab/-/issues/210593
parent
23f894fc
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
14 deletions
+14
-14
doc/ci/environments/index.md
doc/ci/environments/index.md
+5
-6
doc/ci/pipelines/job_artifacts.md
doc/ci/pipelines/job_artifacts.md
+9
-8
No files found.
doc/ci/environments/index.md
View file @
ac60dfc6
...
...
@@ -173,8 +173,8 @@ If you want to use the environment URL in GitLab, you would have to update it ma
To address this problem, you can configure a deployment job to report back a set of
variables, including the URL that was dynamically-generated by the external service.
GitLab supports
[
dotenv
](
https://github.com/bkeepers/dotenv
)
file as th
e format,
and expands the
`environment:url`
value with variables defined in the
dotenv
file.
GitLab supports
the
[
dotenv (`.env`)
](
https://github.com/bkeepers/dotenv
)
fil
e format,
and expands the
`environment:url`
value with variables defined in the
`.env`
file.
To use this feature, specify the
[
`artifacts:reports:dotenv`
](
../pipelines/job_artifacts.md#artifactsreportsdotenv
)
keyword in
`.gitlab-ci.yml`
.
...
...
@@ -213,14 +213,13 @@ stop_review:
As soon as the
`review`
job finishes, GitLab updates the
`review/your-branch-name`
environment's URL.
It parses the
report artifact
`deploy.env`
, registers a list of variables as runtime-created,
It parses the
`deploy.env`
report artifact
, registers a list of variables as runtime-created,
uses it for expanding
`environment:url: $DYNAMIC_ENVIRONMENT_URL`
and sets it to the environment URL.
You can also specify a static part of the URL at
`environment:url:`
, such as
`https://$DYNAMIC_ENVIRONMENT_URL`
. If the value of
`DYNAMIC_ENVIRONMENT_URL`
is
`
123.awesome.com`
, the final result will be
`https://123.awesom
e.com`
.
`
example.com`
, the final result will be
`https://exampl
e.com`
.
The assigned URL for the
`review/your-branch-name`
environment is visible in the UI.
[
See where the environment URL is displayed
](
#using-the-environment-url
)
.
The assigned URL for the
`review/your-branch-name`
environment is
[
visible in the UI
](
#using-the-environment-url
)
.
> **Notes:**
>
...
...
doc/ci/pipelines/job_artifacts.md
View file @
ac60dfc6
...
...
@@ -114,14 +114,15 @@ The `dotenv` report collects a set of environment variables as artifacts.
The collected variables are registered as runtime-created variables of the job,
which is useful to
[
set dynamic environment URLs after a job finishes
](
../environments/index.md#set-dynamic-environment-urls-after-a-job-finishes
)
.
There are a couple of limitations on top of the
[
original dotenv rules
](
https://github.com/motdotla/dotenv#rules
)
.
-
The variable key can contain only letters, digits and underscore ('_').
-
The size of the dotenv file must be smaller than 5 kilobytes.
-
The number of variables must be less than 10.
-
It does not support variable substitution in the dotenv file itself.
-
It does not support empty lines and comments (
`#`
) in dotenv file.
-
It does not support quote escape, spaces in a quote, a new line expansion in a quote, in dotenv file.
There are a couple of exceptions to the
[
original dotenv rules
](
https://github.com/motdotla/dotenv#rules
)
:
-
The variable key can contain only letters, digits, and underscores (
`_`
).
-
The maximum size of the
`.env`
file is 5 KB.
-
The maximum number of variables is 10.
-
Variable substitution in the
`.env`
file is not supported.
-
The
`.env`
file can't have empty lines or comments (starting with
`#`
).
-
Key values in the
`env`
file cannot have spaces or newline characters (
`\n`
), including when using single or double quotes.
-
Quote escaping during parsing (
`key = 'value'`
->
`{key: "value"}`
) is not supported.
#### `artifacts:reports:cobertura`
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment