[nautilus/wip/oholy/ci-buildah] ci: Use buildah instead of docker




commit 61961954ac07296d45ce68d4365ad83faf780f1c
Author: Ondrej Holy <oholy redhat com>
Date:   Thu Nov 19 10:21:15 2020 +0100

    ci: Use buildah instead of docker

 .gitlab-ci.yml | 32 ++++++++++++++++----------------
 1 file changed, 16 insertions(+), 16 deletions(-)
---
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 24a397f64..68d7aba2d 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -32,9 +32,9 @@ fedora rawhide:
         - meson _build .
         - cd _build
         - ninja test
-    only:
-        - web
-        - master
+    #only:
+        #- web
+        #- master
     allow_failure: true
 
 flatpak master:
@@ -88,22 +88,22 @@ style check:
 
 update image:
     variables:
-         DOCKER_TLS_CERTDIR: ""
-    image: docker:latest
+         STORAGE_DRIVER: vfs
+         BUILDAH_FORMAT: docker
+         BUILDAH_ISOLATION: chroot
+    image: registry.fedoraproject.org/fedora:33
     stage: image
-    tags:
-        - privileged
-    services:
-        - docker:dind
     script:
-        - docker build --tag $CI_REGISTRY_IMAGE .gitlab/
-        - docker tag $CI_REGISTRY_IMAGE "$CI_REGISTRY_IMAGE:v$CI_JOB_ID"
-        - docker login $CI_REGISTRY -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD
-        - docker push $CI_REGISTRY_IMAGE
+        - dnf install -y buildah runc
+        - sed -i '/^mountopt =.*/d' /etc/containers/storage.conf
+        - buildah bud --tag $CI_REGISTRY_IMAGE -f .gitlab/Dockerfile
+        - buildah tag $CI_REGISTRY_IMAGE "$CI_REGISTRY_IMAGE:v$CI_JOB_ID"
+        - buildah login $CI_REGISTRY -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD
+        - buildah push $CI_REGISTRY_IMAGE
     when: manual
-    only:
-        - web
-        - master
+    #only:
+        #- web
+        #- master
     except:
         variables:
             - $CI_PROJECT_NAMESPACE != "GNOME"


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