From 93b2f8f94e2810d7bc900bc82bb13b236d9258f0 Mon Sep 17 00:00:00 2001 From: Vladimir Hodakov Date: Mon, 7 Oct 2019 08:55:17 +0400 Subject: [PATCH] Remove Gitlab CI config, add Drone CI config --- .drone.yml | 30 ++++++++++++++++++++++++++++++ .gitlab-ci.yml | 34 ---------------------------------- 2 files changed, 30 insertions(+), 34 deletions(-) create mode 100644 .drone.yml delete mode 100644 .gitlab-ci.yml diff --git a/.drone.yml b/.drone.yml new file mode 100644 index 0000000..86c53d5 --- /dev/null +++ b/.drone.yml @@ -0,0 +1,30 @@ +kind: pipeline +type: docker +name: publish + +steps: +- name: build + image: ruby:2.5-alpine + commands: + - apk add --no-cache g++ musl-dev make + - apk add --no-cache libstdc++ + - bundle install --path=vendor/ + - bundle exec jekyll build -d lorchess.ru +- name: publish + image: appleboy/drone-scp + settings: + host: + from_secret: web_host + username: + from_secret: ssh_user + password: + from_secret: ssh_password + target: + from_secret: web_target + rm: true + strip_components: 1 + source: + - lorchess.ru/* +trigger: + branch: + - master \ No newline at end of file diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml deleted file mode 100644 index f31249d..0000000 --- a/.gitlab-ci.yml +++ /dev/null @@ -1,34 +0,0 @@ -image: ruby:2.5-alpine - -variables: - JEKYLL_ENV: production - LC_ALL: en_US.UTF-8 - -build site: - stage: build - before_script: - - apk add --no-cache g++ musl-dev make - - apk add --no-cache libstdc++ - - bundle install --path=vendor/ - script: - - bundle exec jekyll build -d lorchess.ru - artifacts: - untracked: true - expire_in: 4 hours - paths: - - lorchess.ru - -deploy site: - stage: deploy - only: - - master - before_script: - - apk add --no-cache openssh-client - - mkdir -p ~/.ssh - - echo "$DEPLOY_SSH_KEY" | tr -d '\r' > ~/.ssh/id_rsa - - chmod 600 ~/.ssh/id_rsa - - eval "$(ssh-agent -s)" - - ssh-add ~/.ssh/id_rsa - - ssh-keyscan -H $DEPLOY_SSH_HOST >> ~/.ssh/known_hosts - script: - - scp -r lorchess.ru $DEPLOY_SSH_USER@$DEPLOY_SSH_HOST:$DEPLOY_PATH \ No newline at end of file