mystreamdeck/.drone.yml
Jeffrey C. Ollie d04a7160a5
All checks were successful
continuous-integration/drone/push Build is passing
install service
2020-10-30 12:35:42 -05:00

33 lines
682 B
YAML

---
kind: secret
name: drone-ssh-private-key
get:
path: drone-ssh-key
name: ssh-private-key
---
kind: pipeline
type: ssh
name: build
server:
host: 192.168.4.79
user: root
ssh_key:
from_secret: drone-ssh-private-key
steps:
- name: build
commands:
- go build -v
- name: install
commands:
- mkdir -p /opt/mystreamdeck
- cp mystreamdeck /opt/mystreamdeck-${DRONE_BUILD_STARTED}
- mv /opt/mystreamdeck-${DRONE_BUILD_STARTED} /opt/mystreamdeck/mystreamdeck
- cp mystreamdeck.service /etc/systemd/system
- systemctl daemon-reload
- systemctl restart mystreamdeck.service
- systemctl enable mystreamdeck.service