From: Arnaud Guéras Date: Mon, 16 Sep 2024 04:31:02 +0000 (+0200) Subject: add content to gitlab.yaml X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=b81a43507931e191a59d46c51d4f3ab0dae2e7c4;p=www-xenproject-org.git add content to gitlab.yaml Signed-off-by: Arnaud Guéras --- diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index e69de29..b57ed00 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -0,0 +1,46 @@ +# This file is a template, and might need editing before it works on your project. +# To contribute improvements to CI/CD templates, please follow the Development guide at: +# https://docs.gitlab.com/ee/development/cicd/templates.html +# This specific template is located at: +# https://gitlab.com/gitlab-org/gitlab/-/blob/master/lib/gitlab/ci/templates/Pages/Hugo.gitlab-ci.yml + +--- +# +# Before using this .gitlab-ci.yml: +# +# - This example uses the latest Docker image, but you might want to use the +# exact version to avoid any broken pipelines. +# All available Hugo versions are listed under https://gitlab.com/pages/hugo/container_registry. +# - Read about the difference between hugo and hugo_extended +# https://gitlab.com/pages/hugo/-/blob/main/README.md#hugo-vs-hugo_extended. +# If you don't know what to use, better use the extended version. +# - To change the theme, see +# https://gitlab.com/pages/hugo/-/blob/main/README.md#use-a-custom-theme. +# +default: + image: "${CI_TEMPLATE_REGISTRY_HOST}/pages/hugo/hugo_extended:0.132.2" + +variables: + GIT_SUBMODULE_STRATEGY: recursive + HUGO_ENV: production + + #before_script: + # - apk add --no-cache go curl bash nodejs + # ## Uncomment the following if you use PostCSS. See https://gohugo.io/hugo-pipes/postcss/ + # # - npm install postcss postcss-cli autoprefixer + +test: + script: + - hugo + rules: + - if: $CI_COMMIT_BRANCH != $CI_DEFAULT_BRANCH + +deploy: + script: + - hugo + - tar caf site.tar.gz public + artifacts: + paths: + - site.tar.gz + rules: + - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH