ci: Trigger a pages build
authorEmmanuele Bassi <ebassi@gnome.org>
Sat, 31 Jul 2021 16:08:56 +0000 (17:08 +0100)
committerEmmanuele Bassi <ebassi@gnome.org>
Sat, 31 Jul 2021 16:13:27 +0000 (17:13 +0100)
Do not publish the API reference directly, but trigger a CI pipeline for
the docs-gtk-org branch, which will then do the publishing.

.gitlab-ci.yml

index ad6d2fd79f5e6cc9577bc8b193b139e35aa1dacb..8e42829349125c4a2d61b3d4095401e90d832d3e 100644 (file)
@@ -7,6 +7,7 @@ stages:
   - analysis
   - docs
   - flatpak
+  - publish
   - deploy
 
 .cache-paths: &cache-paths
@@ -337,14 +338,11 @@ reference:
     paths:
       - _reference
 
-pages:
-  stage: deploy
+publish-docs:
+  stage: publish
   needs: ['reference']
   script:
-    - mv _reference/ public/
-    - cp .gitlab-ci/pages/* public/
-  artifacts:
-    paths:
-      - public
+    - "curl -X POST -F token=${PAGES_TRIGGER_TOKEN} -F ref=docs-gtk-org https://gitlab.gnome.org/api/v4/projects/665/trigger/pipeline"
   only:
-    - master
+    refs:
+      - master