From 410e9042c0fa76eda929606ca5e454561d92ca6c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Henrik=20tom=20W=C3=B6rden?= <h.tomwoerden@indiscale.com>
Date: Sat, 13 Mar 2021 15:38:45 +0100
Subject: [PATCH] MAINT: save mariadb image

---
 .gitlab-ci.yml | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index fdee0e2..a843d1c 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -117,8 +117,7 @@ test:
       - echo $CAOSDB_TAG
 
       - time docker load < /image-cache/caosdb-pyint-testenv-${CI_COMMIT_REF_NAME}.tar || true
-      - time docker load < /image-cache/mariadb-${F_BRANCH}.tar || true
-      - time docker load < /image-cache/caosdb-${F_BRANCH}.tar || true
+      - time docker load < /image-cache/mariadb.tar || true
       - docker pull $CI_REGISTRY_IMAGE
       - cd .docker
         # here the server and the mysql backend docker are being started
@@ -136,6 +135,8 @@ test:
       - docker logs docker_sqldb_1 &> ../mariadb_log.txt
       - docker-compose -f .docker/docker-compose.yml down
       - rc=`cat .docker/result`
+      - echo $(docker image ls mariadb | grep mariadb | awk '{print $2}')
+      - docker save $(docker image ls mariadb | grep mariadb | awk '{print $2}') > /image-cache/mariadb.tar || true
       - exit $rc
   dependencies: [cert]
   timeout: 3h
@@ -151,6 +152,9 @@ build-testenv:
   image: docker:19.03
   stage: setup
   timeout: 2h
+  only:
+    - shedules
+    - web
   needs: []
   script:
       - df -h
-- 
GitLab