From 2fb52394e6e625f0758fff98358b92a1d7016950 Mon Sep 17 00:00:00 2001 From: Alexander Schlemmer <a.schlemmer@indiscale.com> Date: Wed, 25 Jan 2023 14:44:44 +0000 Subject: [PATCH] MAINT: Update .gitlab-ci.yml file to automatically build gitlab pages for the documentation --- .gitlab-ci.yml | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index bfac6b00..42810175 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -277,3 +277,26 @@ style: script: - autopep8 -r --diff --exit-code . allow_failure: true + +# Build the sphinx documentation and make it ready for deployment by Gitlab Pages +# Special job for serving a static website. See https://docs.gitlab.com/ee/ci/yaml/README.html#pages +# Based on: https://gitlab.indiscale.com/caosdb/src/caosdb-pylib/-/ci/editor?branch_name=main +pages_prepare: &pages_prepare + tags: [ cached-dind ] + stage: deploy + needs: [] + only: + refs: + - /^release-.*$/i + script: + - echo "Deploying documentation" + - make doc + - cp -r build/doc/html public + artifacts: + paths: + - public +pages: + <<: *pages_prepare + only: + refs: + - main -- GitLab