diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 634598f1f53a0d306c7d983716fac8dbe4e8e77c..ebe60944997f06a70e372305b4d8838bbb31fdba 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -23,7 +23,9 @@ build: production: stage: deploy + image: alpine:3.1 + before_script: - 'which ssh-agent || ( apk add --update openssh )' - eval $(ssh-agent -s) @@ -32,7 +34,9 @@ production: - 'echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config' - echo "$KNOWNHOSTS" > ~/.ssh/known_hosts - chmod 644 ~/.ssh/known_hosts + rules: - if: '$CI_COMMIT_BRANCH == "develop"' + script: - scp -P $SSHPORT -r public/* $SSHCONNECT:~/web/latest