mirror of
https://git.klmp200.net/ALFRED/ALFRED.git
synced 2025-01-18 10:36:44 +01:00
34 lines
893 B
YAML
34 lines
893 B
YAML
pipeline:
|
|
build:
|
|
image: golang:1.11
|
|
group: build
|
|
commands:
|
|
- go get -v -d ./...
|
|
- go build .
|
|
test:
|
|
image: golang:1.11
|
|
group: test
|
|
secrets: [ test_api_token ]
|
|
environment: [ test_api_token ]
|
|
commands:
|
|
- go get -v -d ./...
|
|
- go test ./...
|
|
publish:
|
|
image: plugins/docker
|
|
repo: klmp200/alfred
|
|
secrets: [ docker_username, docker_password ]
|
|
when:
|
|
branch: master
|
|
event: push
|
|
deploy:
|
|
image: appleboy/drone-ssh
|
|
host:
|
|
- ollivander.diagon-alley
|
|
username: dronedeploy
|
|
secrets: [ ssh_password ]
|
|
envs: [ ssh_password ]
|
|
script:
|
|
- echo $SSH_PASSWORD | sudo -S systemctl restart alfred-bot
|
|
when:
|
|
branch: master
|
|
event: push |