cv/.drone.yml

54 lines
958 B
YAML
Raw Normal View History

kind: pipeline
2021-08-08 20:01:11 +02:00
type: exec
name: deploy CV
steps:
2021-08-08 20:01:11 +02:00
- name: build
commands:
2022-06-20 14:44:38 +02:00
- nix build
2021-08-08 20:04:13 +02:00
- name: check
commands:
- nix flake check
2021-08-08 20:01:11 +02:00
- name: deploy
commands:
2022-06-20 14:37:02 +02:00
- nix run github:ambroisie/nix-config#drone-rsync
2021-08-08 20:01:11 +02:00
environment:
2022-06-20 14:44:38 +02:00
# Use trailing slash to sync to folder's *content* to the target
SYNC_SOURCE: 'result/share/'
2022-06-20 14:37:02 +02:00
SYNC_HOST:
2021-08-08 20:01:11 +02:00
from_secret: ssh_host
2022-06-20 14:37:02 +02:00
SYNC_TARGET:
2021-08-08 20:01:11 +02:00
from_secret: ssh_target
2022-06-20 14:37:02 +02:00
SYNC_USERNAME:
2021-08-08 20:01:11 +02:00
from_secret: ssh_user
2022-06-20 14:37:02 +02:00
SYNC_KEY:
2021-08-08 20:01:11 +02:00
from_secret: ssh_key
2022-06-20 14:37:02 +02:00
SYNC_PORT:
2021-08-08 20:01:11 +02:00
from_secret: ssh_port
when:
branch:
- main
event:
exclude:
- pull_request
2020-10-14 18:35:40 +02:00
2021-08-08 20:01:11 +02:00
- name: notifiy
commands:
- nix run github:ambroisie/matrix-notifier
environment:
ADDRESS:
from_secret: matrix_homeserver
ROOM:
from_secret: matrix_roomid
USER:
from_secret: matrix_username
PASS:
from_secret: matrix_password
when:
status:
- failure
- success