From c8042df2fad7b45b5da913ad5ecce0074369cc9c Mon Sep 17 00:00:00 2001 From: AleaJactaEst Date: Wed, 11 Apr 2018 12:12:22 +0200 Subject: [PATCH] change compress method for khanat image --- .gitlab-ci.yml | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 8b018a7..61356b3 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -89,16 +89,15 @@ Linux server build: # Clean - rm -f /opt/servercontainer* # Create image - - mkdir -p out - option="" - for dir in /home/* ; do if [ $dir != '/home/gameserver' ] ; then option="$option --exclude=$dir" ; fi ; done - echo "option '$option'" - - du -sh /home/gameserver - - tar --numeric-owner --exclude=.git --exclude=.dockerenv --exclude=/proc --exclude=/sys --exclude=/builds --exclude=/opt/download $option -cjf out/debian_server.tar / - - ls -lh out + - find /home/gameserver -type d -exec du -sh {} \; + - tar --numeric-owner --exclude=.git --exclude=.dockerenv --exclude=/proc --exclude=/sys --exclude=/builds --exclude=/opt/download --exclude=khanat-debian-server.tar.gz $option -czf khanat-debian-server.tar.gz / + - ls -lh khanat-debian-server.tar.gz artifacts: name: "khanat-$(echo $CI_BUILD_REF | head -c 7 )-$CI_PIPELINE_ID-server-debian-stretch" paths: - - out + - khanat-debian-server.tar.gz expire_in: 2 hour