From 06f97ad3166eb355dd80c2a324340aa0ae668de5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?An=C5=BEe=20=C5=BDitnik?= <anze.zitnik@xlab.si> Date: Tue, 18 Jan 2022 13:49:44 +0100 Subject: [PATCH] Add docker push to MEDINA artifactory to CI script --- .gitignore | 5 ++++- .gitlab-ci.yml | 8 ++++++++ 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 3d204c2..2aa9537 100644 --- a/.gitignore +++ b/.gitignore @@ -2,4 +2,7 @@ __pycache__/ *.pyc *$py.class .idea/ -dump.rdb \ No newline at end of file +dump.rdb +env/ +venv/ + diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 81d2ebe..82172d1 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -2,6 +2,8 @@ image: nexus-registry.xlab.si:5001/docker:dind variables: REGISTRY: registry-gitlab.xlab.si + MEDINA_REGISTRY: optima-medina-docker-dev.artifact.tecnalia.com + MEDINA_REG_PATH: wp3/t32 before_script: - export SERVICE=$(grep SERVICE MANIFEST | cut -d '=' -f2) @@ -35,5 +37,11 @@ push: - docker push $REGISTRY/medina/$SERVICE:$VERSION - docker push $REGISTRY/medina/$SERVICE:latest - docker logout $REGISTRY + - docker login $MEDINA_REGISTRY -u medina.fordevelopers@gmail.com -p AKCp8kqMZkcPRPGZhHBw7uKFsyifF1iHb2ZvbBy5PK88wD8EdeSHZqFsc4h1wp3M2oVYGazhv + - docker tag $REGISTRY/medina/$SERVICE:$VERSION $MEDINA_REGISTRY/$MEDINA_REG_PATH/$SERVICE:$VERSION + - docker tag $REGISTRY/medina/$SERVICE:$VERSION $MEDINA_REGISTRY/$MEDINA_REG_PATH/$SERVICE:latest + - docker push $MEDINA_REGISTRY/$MEDINA_REG_PATH/$SERVICE:$VERSION + - docker push $MEDINA_REGISTRY/$MEDINA_REG_PATH/$SERVICE:latest + - docker logout $MEDINA_REGISTRY only: - master -- GitLab