[retro-gtk] ci: Separate the pipeline into multiple stages
- From: Adrien Plazas <aplazas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [retro-gtk] ci: Separate the pipeline into multiple stages
- Date: Sat, 9 Jun 2018 08:50:38 +0000 (UTC)
commit 1fd39dbff0898fb769edc812a7e765cd3207fd0a
Author: Alexander Mikhaylenko <exalm7659 gmail com>
Date: Fri Jun 8 16:40:54 2018 +0500
ci: Separate the pipeline into multiple stages
Move unit tests into 'test' stage, and flatpak deployment into 'review'
stage. Also add a 'stop_review' manual job and change expiration date to
30 days.
.gitlab-ci.yml | 40 +++++++++++++++++++++++++++++++++-------
1 file changed, 33 insertions(+), 7 deletions(-)
---
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 183e438..14b3ac8 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -5,11 +5,16 @@
- ninja -C _build install
stages:
- - build-flatpak
+ - build
+ - test
+ - review
-flatpak:unit-tests:
+variables:
+ BUNDLE: "retro-demo-samples-test-git.flatpak"
+
+flatpak:tests:
image: registry.gitlab.gnome.org/gnome/gnome-nightly-oci/nightly:master
- stage: build-flatpak
+ stage: test
variables:
MANIFEST_PATH: "flatpak/org.gnome.Retro.UnitTests.json"
FLATPAK_MODULE: "retro-gtk"
@@ -25,15 +30,14 @@ flatpak:unit-tests:
paths:
- .flatpak-builder/cache/
-flatpak:demo-samples-test:
+flatpak:demo:
image: registry.gitlab.gnome.org/gnome/gnome-nightly-oci/nightly:master
- stage: build-flatpak
+ stage: build
variables:
MANIFEST_PATH: "flatpak/org.gnome.Retro.DemoSamplesTest.json"
RUNTIME_REPO: "https://sdk.gnome.org/gnome-nightly.flatpakrepo"
FLATPAK_MODULE: "retro-gtk"
FLATPAK_BUILD_DIR: "app"
- BUNDLE: "retro-demo-samples-test-git.flatpak"
script:
- flatpak-builder --stop-at=${FLATPAK_MODULE} ${FLATPAK_BUILD_DIR} ${MANIFEST_PATH}
- flatpak build ${FLATPAK_BUILD_DIR} meson --prefix=/app ${MESON_ARGS} _build
@@ -45,10 +49,32 @@ flatpak:demo-samples-test:
paths:
- ${BUNDLE}
- _build/meson-logs/meson-log.txt
- expire_in: 2 days
+ expire_in: 30 days
cache:
paths:
- .flatpak-builder/cache/
+
+review:
+ stage: review
+ dependencies:
+ - flatpak:demo
+ - flatpak:tests
+ script:
+ - echo "Generating flatpak deployment"
+ artifacts:
+ paths:
+ - ${BUNDLE}
+ expire_in: 30 days
environment:
name: review/$CI_COMMIT_REF_NAME
url: https://gitlab.gnome.org/$CI_PROJECT_PATH/-/jobs/$CI_JOB_ID/artifacts/raw/${BUNDLE}
+ on_stop: stop_review
+
+stop_review:
+ stage: review
+ script:
+ - echo "Stopping flatpak deployment"
+ when: manual
+ environment:
+ name: review/$CI_COMMIT_REF_NAME
+ action: stop
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]