From eca028d609000dcc140e9bf1a03288590b8e24e5 Mon Sep 17 00:00:00 2001 From: John Ellson Date: Mon, 15 Jul 2019 21:38:26 -0400 Subject: [PATCH] WIP deploy - addind createrepo --- .gitlab-ci.yml | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 88349465e..e7357572b 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -26,9 +26,10 @@ portable-source: - rm -rf /home/gitlab-runner/rpmbuild - GV_VERSION=$( cat VERSION ) - rpmbuild -ta graphviz-${GV_VERSION}.tar.gz - - DISTRO_NAME=$( cat /etc/redhat-release | cut -d' ' -f1 | tr 'A-Z' 'a-z' ) - - DISTRO_VERSION=$( cat /etc/redhat-release | cut -d' ' -f3 ) - - DIR=Packages/${DISTRO_NAME}/${DISTRO_VERSION} + - ID=$( cat /etc/redhat-release | cut -d' ' -f1 | tr 'A-Z' 'a-z' ) + - VERSION_ID=$( cat /etc/redhat-release | cut -d' ' -f3 ) + - if test -f /etc/os-release; then . /etc/os-release; fi + - DIR=Packages/${ID}/${VERSION_ID} - ARCH=$( uname -m ) - mkdir -p ${DIR}/os/${ARCH} - mkdir -p ${DIR}/debug/${ARCH} @@ -132,4 +133,7 @@ deployment: - chmod 700 ~/.ssh - ssh-keyscan "$DEPLOY_HOST" >> ~/.ssh/known_hosts - chmod 644 ~/.ssh/known_hosts + - chmod -R go-rx Packages + - chmod -R +X Packages - scp -r Packages "$DEPLOY_USER"@"$DEPLOY_HOST"':' + - ssh "$DEPLOY_USER"@"$DEPLOY_HOST" 'for i in Packages/centos/* Packages/fedora/*; do createrepo $i; done' -- 2.40.0