From 3b16dee092694e33b09e3b023226de6498647462 Mon Sep 17 00:00:00 2001 From: philipp lang Date: Tue, 13 Feb 2024 01:01:15 +0100 Subject: [PATCH] Add drone --- .drone.yml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .drone.yml diff --git a/.drone.yml b/.drone.yml new file mode 100644 index 0000000..718d68a --- /dev/null +++ b/.drone.yml @@ -0,0 +1,31 @@ +kind: pipeline +type: docker +name: default + +workspace: + path: /drone/nami + +steps: + - name: node + image: node:18.13.0-slim + commands: + - npm ci && npm run production + + - name: deploy + image: php:8.1.6 + environment: + SSH_KEY: + from_secret: deploy_private_key + commands: + - apt-get update > /dev/null + - apt-get install -y openssh-client + - mkdir $HOME/.ssh + - echo "UserKnownHostsFile=/dev/null" >> $HOME/.ssh/config + - echo "StrictHostKeyChecking=no" >> $HOME/.ssh/config + - echo "$SSH_KEY" > $HOME/.ssh/id_rsa + - chmod 600 $HOME/.ssh/id_rsa + - rsync --delete -avzze ssh /drone/nami disco@zoomyboy.de:discotest + +trigger: + branch: + - master