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
0
Merge Requests
0
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
Boxiang Sun
gitlab-ce
Commits
82012d46
Commit
82012d46
authored
Jun 25, 2018
by
Achilleas Pipinellis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Always run review app for docs-only branches
parent
2bac2918
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
32 additions
and
19 deletions
+32
-19
.gitlab-ci.yml
.gitlab-ci.yml
+31
-18
scripts/trigger-build-docs
scripts/trigger-build-docs
+1
-1
No files found.
.gitlab-ci.yml
View file @
82012d46
...
...
@@ -220,18 +220,6 @@ stages:
paths
:
-
log/development.log
# Review docs base
.review-docs
:
&review-docs
<<
:
*dedicated-runner
<<
:
*except-qa
<<
:
*single-script-job
variables
:
<<
:
*single-script-job-variables
SCRIPT_NAME
:
trigger-build-docs
when
:
manual
only
:
-
branches
# DB migration, rollback, and seed jobs
.db-migrate-reset
:
&db-migrate-reset
<<
:
*dedicated-no-docs-and-no-qa-pull-cache-job
...
...
@@ -273,20 +261,44 @@ package-and-qa:
-
//@gitlab-org/gitlab-ce
-
//@gitlab-org/gitlab-ee
# Trigger a docs build in gitlab-docs
# Useful to preview the docs changes live
review-docs-deploy
:
<<
:
*review-docs
stage
:
build
# Review docs base
.review-docs
:
&review-docs
<<
:
*dedicated-runner
<<
:
*single-script-job
variables
:
<<
:
*single-script-job-variables
SCRIPT_NAME
:
trigger-build-docs
environment
:
name
:
review-docs/$CI_COMMIT_REF_NAME
# DOCS_REVIEW_APPS_DOMAIN and DOCS_GITLAB_REPO_SUFFIX are secret variables
# Discussion: https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/14236/diffs#note_40140693
url
:
http://$DOCS_GITLAB_REPO_SUFFIX-$CI_
COMMIT_REF
_SLUG.$DOCS_REVIEW_APPS_DOMAIN/$DOCS_GITLAB_REPO_SUFFIX
url
:
http://$DOCS_GITLAB_REPO_SUFFIX-$CI_
ENVIRONMENT
_SLUG.$DOCS_REVIEW_APPS_DOMAIN/$DOCS_GITLAB_REPO_SUFFIX
on_stop
:
review-docs-cleanup
# Trigger a manual docs build in gitlab-docs only on non docs-only branches.
# Useful to preview the docs changes live.
review-docs-deploy-manual
:
<<
:
*review-docs
stage
:
build
script
:
-
gem install gitlab --no-ri --no-rdoc
-
./$SCRIPT_NAME deploy
when
:
manual
only
:
-
branches
<<
:
*except-docs-and-qa
# Always trigger a docs build in gitlab-docs only on docs-only branches.
# Useful to preview the docs changes live.
review-docs-deploy
:
<<
:
*review-docs
stage
:
post-test
script
:
-
gem install gitlab --no-ri --no-rdoc
-
./$SCRIPT_NAME deploy
only
:
-
/(^docs[\/-].*|.*-docs$)/
<<
:
*except-qa
# Cleanup remote environment of gitlab-docs
review-docs-cleanup
:
...
...
@@ -295,6 +307,7 @@ review-docs-cleanup:
environment
:
name
:
review-docs/$CI_COMMIT_REF_NAME
action
:
stop
when
:
manual
script
:
-
gem install gitlab --no-ri --no-rdoc
-
./SCRIPT_NAME cleanup
...
...
scripts/trigger-build-docs
View file @
82012d46
...
...
@@ -27,7 +27,7 @@ def docs_branch
# Prefix the remote branch with the slug of the project in order
# to avoid name conflicts in the rare case the branch name already
# exists in the docs repo and truncate to max length.
"
#{
slug
}
-
#{
ENV
[
"CI_
COMMIT_REF
_SLUG"
]
}
"
[
0
...
max
]
"
#{
slug
}
-
#{
ENV
[
"CI_
ENVIRONMENT
_SLUG"
]
}
"
[
0
...
max
]
end
#
...
...
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