[gnome-control-center/alatiera/citemplate] CI test




commit 0b24d6134dfb611fe42b161942a1caa9557fa091
Author: Jordan Petridis <jordan centricular com>
Date:   Thu Jul 22 05:33:09 2021 +0300

    CI test

 .gitlab-ci.yml | 167 +++++++++++++++++++++++++++++----------------------------
 1 file changed, 86 insertions(+), 81 deletions(-)
---
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 4a2aeed1b..a0dcdf2c5 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -2,66 +2,9 @@ include:
  - remote: 
'https://gitlab.freedesktop.org/freedesktop/ci-templates/-/raw/5888c7388134cbe4661600222fe9befb10441f6e/templates/fedora.yml'
 
 variables:
-  FDO_DISTRIBUTION_TAG: latest
-  FDO_DISTRIBUTION_VERSION: rawhide
   FDO_UPSTREAM_REPO: gnome/gnome-control-center
-  # Expiry sets fdo.expires on the image
-  FDO_EXPIRES_AFTER: 8w
-  FEDORA_IMAGE: "$CI_REGISTRY/$FDO_UPSTREAM_REPO/fedora/$FDO_DISTRIBUTION_VERSION:$FDO_DISTRIBUTION_TAG"
-  # NOTES:
-  # - gobject-introspection-devel is needed for gsettings-desktop-schemas
-  FEDORA_DEPENDENCIES: >
-    @c-development @development-tools
-    git
-    llvm clang libasan libtsan libubsan gcovr
-    meson
-    accountsservice-devel
-    cheese-libs-devel
-    chrpath
-    colord-devel colord-gtk-devel
-    cups-devel
-    desktop-file-utils
-    docbook-style-xsl
-    flatpak-devel
-    gdk-pixbuf2-devel
-    gettext
-    glib2-devel
-    gobject-introspection-devel
-    gnome-bluetooth-libs-devel
-    gnome-desktop3-devel
-    gnome-online-accounts-devel
-    gnome-settings-daemon-devel
-    grilo-devel
-    gsettings-desktop-schemas-devel
-    gsound-devel
-    gtk3-devel ibus-devel
-    intltool
-    libcanberra-devel
-    libgtop2-devel
-    libgudev-devel
-    libnma-devel
-    libpwquality-devel
-    libsmbclient-devel
-    libsoup-devel
-    libudisks2-devel
-    libwacom-devel
-    libX11-devel
-    libXi-devel
-    libxml2-devel
-    libxslt
-    ModemManager-glib-devel
-    NetworkManager-libnm-devel
-    polkit-devel
-    pulseaudio-libs-devel
-    upower-devel
-    python3-dbusmock
-    xorg-x11-server-Xvfb
-    mesa-dri-drivers
-    libsecret-devel
   GIT_SUBMODULE_STRATEGY: normal
 
-image: "$FEDORA_IMAGE"
-
 stages:
   - build
   - test
@@ -96,6 +39,83 @@ stages:
   echo "== Testing ==" &&
   meson test -C _build --verbose --no-stdsplit
 
+#############################################
+#          Create CI Docker Images          #
+#############################################
+
+# See also https://gitlab.freedesktop.org/freedesktop/ci-templates
+.fedora.container.common:
+  extends: .fdo.container-build@fedora
+  variables:
+    GIT_STRATEGY: none # no need to pull the whole tree for rebuilding the image
+    FDO_DISTRIBUTION_TAG: '2021-07-22.0-main'
+    FDO_DISTRIBUTION_VERSION: rawhide
+    # Expiry sets fdo.expires on the image
+    FDO_EXPIRES_AFTER: 8w
+    FEDORA_IMAGE: "$CI_REGISTRY/$FDO_UPSTREAM_REPO/fedora/$FDO_DISTRIBUTION_VERSION:$FDO_DISTRIBUTION_TAG"
+    # NOTES:
+    # - gobject-introspection-devel is needed for gsettings-desktop-schemas
+    FDO_DISTRIBUTION_PACKAGES: >
+      @c-development @development-tools
+      git
+      llvm clang libasan libtsan libubsan gcovr
+      meson
+      accountsservice-devel
+      cheese-libs-devel
+      chrpath
+      colord-devel colord-gtk-devel
+      cups-devel
+      desktop-file-utils
+      docbook-style-xsl
+      flatpak-devel
+      gdk-pixbuf2-devel
+      gettext
+      glib2-devel
+      gobject-introspection-devel
+      gnome-bluetooth-libs-devel
+      gnome-desktop3-devel
+      gnome-online-accounts-devel
+      gnome-settings-daemon-devel
+      grilo-devel
+      gsettings-desktop-schemas-devel
+      gsound-devel
+      gtk3-devel ibus-devel
+      intltool
+      libcanberra-devel
+      libgtop2-devel
+      libgudev-devel
+      libnma-devel
+      libpwquality-devel
+      libsmbclient-devel
+      libsoup-devel
+      libudisks2-devel
+      libwacom-devel
+      libX11-devel
+      libXi-devel
+      libxml2-devel
+      libxslt
+      ModemManager-glib-devel
+      NetworkManager-libnm-devel
+      polkit-devel
+      pulseaudio-libs-devel
+      upower-devel
+      python3-dbusmock
+      xorg-x11-server-Xvfb
+      mesa-dri-drivers
+      libsecret-devel
+    FDO_DISTRIBUTION_EXEC: |
+      git clone https://gitlab.gnome.org/GNOME/gsettings-desktop-schemas.git && \
+        cd gsettings-desktop-schemas && \
+        meson . _build --prefix=/usr && \
+        ninja -C _build && \
+        ninja -C _build install && \
+        cd ..
+
+.build.container.fedora@x86_64:
+  extends:
+    - '.fdo.container-build@fedora@x86_64'
+    - '.fedora.container.common'
+
 ##
 # Stage: Build
 #
@@ -104,6 +124,7 @@ stages:
 # any of them.
 ##
 build:
+  extends: '.fdo.distribution-image@fedora'
   <<: *save_untracked_files
   stage: build
 
@@ -130,6 +151,7 @@ build:
 # Runs the unit tests.
 ##
 test:
+  extends: '.fdo.distribution-image@fedora'
   <<: *save_build_logs
   stage: test
 
@@ -153,6 +175,7 @@ test:
 
 # Runs the coverage test.
 coverage:
+  extends: '.fdo.distribution-image@fedora'
   <<: *save_build_logs
   stage: test
   variables:
@@ -187,6 +210,7 @@ coverage:
 # Publishes the Coverage Report generated above
 ##
 pages:
+  extends: '.fdo.distribution-image@fedora'
   stage: deploy
   dependencies:
     - coverage
@@ -267,6 +291,7 @@ flatpak:
 
 # Runs the sanitizers [address, thread, undefined, and memory].
 .sanitizer: &sanitizer
+  extends: '.fdo.distribution-image@fedora'
   <<: *save_build_logs
   stage: manual
   when: manual
@@ -281,6 +306,7 @@ flatpak:
       - $CI_COMMIT_TITLE =~ /^Update.*translation$/
 
 asan:
+  extends: '.fdo.distribution-image@fedora'
   <<: *sanitizer
   # ASAN requires debugging capabilities
   tags: [ asan ]
@@ -291,41 +317,20 @@ asan:
     LSAN_OPTIONS: "suppressions=${CI_PROJECT_DIR}/build-aux/ci/lsan.supp"
 
 tsan:
+  extends: '.fdo.distribution-image@fedora'
   <<: *sanitizer
   variables:
     BUILD_OPTS: "-Db_sanitize=thread"
 
 ubsan:
+  extends: '.fdo.distribution-image@fedora'
   <<: *sanitizer
   variables:
     BUILD_OPTS: "-Db_sanitize=undefined"
 
 msan:
+  extends: '.fdo.distribution-image@fedora'
   <<: *sanitizer
   variables:
     BUILD_OPTS: "-Db_sanitize=memory"
     CC: "clang"
-
-#############################################
-#          Create CI Docker Images          #
-#############################################
-
-# See also https://gitlab.freedesktop.org/freedesktop/ci-templates
-container_fedora_build:
-  extends: .fdo.container-build@fedora
-  # The templates reference the local registry, but we need the fdo one
-  only:
-    variables:
-      - $CI_PIPELINE_SOURCE == "schedule" && $CRON_TASK == "BUILD_CI_IMAGES"
-  variables:
-    GIT_STRATEGY: none # no need to pull the whole tree for rebuilding the image
-    FDO_FORCE_REBUILD: 1 # Force rebuilding the image
-    FDO_DISTRIBUTION_PACKAGES: $FEDORA_DEPENDENCIES
-    FDO_DISTRIBUTION_EXEC: |
-      git clone https://gitlab.gnome.org/GNOME/gsettings-desktop-schemas.git && \
-        cd gsettings-desktop-schemas && \
-        meson . _build --prefix=/usr && \
-        ninja -C _build && \
-        ninja -C _build install && \
-        cd ..
-


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]