Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
MACAO Hugo
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
MACAO
MACAO Hugo
Commits
acb0eb4a
Commit
acb0eb4a
authored
11 months ago
by
Eliott Sammier
Browse files
Options
Downloads
Patches
Plain Diff
More comments in Gitlab-CI config
parent
74f3c4d9
Branches
Branches containing commit
No related tags found
No related merge requests found
Pipeline
#1967
passed
11 months ago
Stage: test
Stage: deploy
Changes
1
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
.gitlab-ci.yml
+18
-2
18 additions, 2 deletions
.gitlab-ci.yml
with
18 additions
and
2 deletions
.gitlab-ci.yml
+
18
−
2
View file @
acb0eb4a
# From template at https://gitlab.com/pages/hugo
# Runner configuration
default
:
# The `hugo_extended` image is required because our theme needs SCSS compilation
# (see https://gohugo.io/installation/linux/#editions)
# The image is pinned to an explicit version number to avoid bugs introduced
# by an automatic upgrade
image
:
"
${CI_TEMPLATE_REGISTRY_HOST}/pages/hugo/hugo_extended:0.128.1"
variables
:
GIT_SUBMODULE_STRATEGY
:
recursive
# include Hugo themes
GIT_SUBMODULE_FORCE_HTTPS
:
true
GIT_SUBMODULE_FORCE_HTTPS
:
true
# the GitLab runner doesn't have SSH to clone
HUGO_ENV
:
production
# Jobs configuration
# In this project, the Hugo directory (with `hugo.toml`, `content/` etc...) is
# not the Git root dir, but a subfolder `macao`. This requires a bit of extra
# config for some jobs.
test
:
# The `test` job just tries to build the site, runs on all branches except
# the default
script
:
-
cd macao
-
cd macao
# move to the hugo dir
-
hugo
rules
:
-
if
:
$CI_COMMIT_BRANCH != $CI_DEFAULT_BRANCH
pages
:
# The `pages` job builds the site to the `public` dir for Pages to publish,
# runs only on the default branch
script
:
-
cd macao
-
hugo
# Declare an artifact, the job's output
artifacts
:
paths
:
-
macao/public
# Config for Pages: directory to serve (default is 'public')
publish
:
macao/public
rules
:
-
if
:
$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment