Compress the CI release artifacts before passing to upload
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
parent
3f5f86db99
commit
312e71d3ec
|
@ -210,14 +210,19 @@ package-app:
|
||||||
stage: package
|
stage: package
|
||||||
variables: &release-variables
|
variables: &release-variables
|
||||||
MIX_ENV: "prod"
|
MIX_ENV: "prod"
|
||||||
|
APP_VERSION: "${CI_COMMIT_TAG}"
|
||||||
|
APP_ASSET: "${CI_PROJECT_NAME}_${APP_VERSION}_${ARCH}.tar.gz"
|
||||||
script: &release-script
|
script: &release-script
|
||||||
- mix local.hex --force
|
- mix local.hex --force
|
||||||
- mix local.rebar --force
|
- mix local.rebar --force
|
||||||
- mix deps.get && mix tz_world.update
|
- mix deps.get && mix tz_world.update
|
||||||
- mix phx.digest
|
- mix phx.digest
|
||||||
- mix release --path release/mobilizon
|
- mix release --path release/mobilizon
|
||||||
- cd release/mobilizon && ln -s lib/mobilizon-*/priv priv
|
- cd release/mobilizon && ln -s lib/mobilizon-*/priv priv && cd ../../
|
||||||
- du -sh release/
|
- du -sh release/
|
||||||
|
- 'echo "Artifact: ${APP_ASSET}"'
|
||||||
|
- tar czf ${APP_ASSET} -C release mobilizon
|
||||||
|
- du -sh ${APP_ASSET}
|
||||||
only:
|
only:
|
||||||
- tags@framasoft/mobilizon
|
- tags@framasoft/mobilizon
|
||||||
artifacts:
|
artifacts:
|
||||||
|
@ -240,14 +245,10 @@ release-upload:
|
||||||
stage: upload
|
stage: upload
|
||||||
image: framasoft/yakforms-assets-deploy:latest
|
image: framasoft/yakforms-assets-deploy:latest
|
||||||
rules: *tag-rules
|
rules: *tag-rules
|
||||||
|
variables:
|
||||||
|
APP_VERSION: "${CI_COMMIT_TAG}"
|
||||||
|
APP_ASSET: "${CI_PROJECT_NAME}_${APP_VERSION}_${ARCH}.tar.gz"
|
||||||
script:
|
script:
|
||||||
- APP_VERSION="${CI_COMMIT_TAG}"
|
|
||||||
- APP_ASSET="${CI_PROJECT_NAME}_${APP_VERSION}_${ARCH}.tar.gz"
|
|
||||||
|
|
||||||
- 'echo "Artifact: ${APP_ASSET}"'
|
|
||||||
- tar czf ${APP_ASSET} -C release mobilizon
|
|
||||||
- ls -al ${APP_ASSET}
|
|
||||||
|
|
||||||
- eval `ssh-agent -s`
|
- eval `ssh-agent -s`
|
||||||
- ssh-add <(echo "${DEPLOYEMENT_KEY}" | base64 --decode -i)
|
- ssh-add <(echo "${DEPLOYEMENT_KEY}" | base64 --decode -i)
|
||||||
- echo "put -r ${APP_ASSET}" | sftp -o "VerifyHostKeyDNS yes" ${DEPLOYEMENT_USER}@${DEPLOYEMENT_HOST}:public/
|
- echo "put -r ${APP_ASSET}" | sftp -o "VerifyHostKeyDNS yes" ${DEPLOYEMENT_USER}@${DEPLOYEMENT_HOST}:public/
|
||||||
|
|
Loading…
Reference in a new issue