diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index ec73d9b8..3f484d88 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -3,7 +3,10 @@ image: alpine:latest pages: stage: deploy script: - - echo 'Nothing to do...' + - if [ ! -z ${DEPLOYEMENT_KNOWN_HOSTS+x} ]; then echo -e "${DEPLOYEMENT_KNOWN_HOSTS}" > ${HOME}/.ssh/known_hosts; fi + - eval `ssh-agent -s` + - if [ ! -z ${DEPLOYEMENT_KEY+x} ]; then ssh-add <(echo "${DEPLOYEMENT_KEY}" | base64 --decode -i); fi + - if [ ! -z ${DEPLOYEMENT_KEY+x} ]; then rsync -a --delete --exclude stats/ --exclude error/ public/ ${DEPLOYEMENT_USER}@${DEPLOYEMENT_HOST}:../../web/; fi artifacts: paths: - public