Sandbox update fix

This commit is contained in:
Adam Štrauch 2021-10-26 23:13:20 +02:00
parent 3fb5c217e4
commit 0a6789c56c
Signed by: cx
GPG key ID: 018304FFA8988F8D

View file

@ -36,18 +36,19 @@ steps:
commands:
- go mod tidy
- make build
- name: deploy
image: debian:buster
environment:
NODE: node-x.rosti.cz
SSH_KEY:
from_secret: ssh_key
from_secret: SSH_KEY
commands:
- apt update && apt install -y ssh
- mkdir ~/.ssh && echo $SSH_KEY > ~/.ssh/id_key && chmod 600 ~/.ssh/id_key
- scp node-api root@$NODES:/usr/local/bin/node-api_
- ssh root@$NODES mv /usr/local/bin/node-api_ /usr/local/bin/node-api
- ssh root@$NODES systemctl restart node-api
- scp node-api root@$NODE:/usr/local/bin/node-api_
- ssh root@$NODE mv /usr/local/bin/node-api_ /usr/local/bin/node-api
- ssh root@$NODE systemctl restart node-api
trigger:
branch:
@ -55,3 +56,6 @@ trigger:
event:
- push
- custom
depends_on:
- test