From 9a92ad16e288d4a1d5550388cb0633dd994af370 Mon Sep 17 00:00:00 2001 From: Varac Date: Wed, 27 Sep 2017 11:48:55 +0200 Subject: Deploy changes to website from CI --- .gitlab-ci.yml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 .gitlab-ci.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..745791b --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,19 @@ +--- +image: 0xacab.org:4567/leap/docker/ruby:stretch_amd64 + +deploy: + environment: + name: production + only: + - master + before_script: + # install ssh-agent + - 'which ssh-agent || ( apt-get update -y && apt-get install openssh-client -y )' + # run ssh-agent + - eval $(ssh-agent -s) + # add ssh key stored in SSH_PRIVATE_KEY variable to the agent store + - ssh-add <(echo "$SSH_PRIVATE_KEY") + script: + - apt-get update + - apt-get install -y --no-install-recommends capistrano + - cap deploy -- cgit v1.2.3