-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy path.drone.yml
55 lines (46 loc) · 1.36 KB
/
.drone.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
---
kind: pipeline
type: exec
name: default
concurrency:
limit: 1
clone:
disable: true
steps:
- name: pull
commands:
- eval `ssh-agent -s`
- ssh-add /home/dreamland/.ssh/drone
- cd /var/www/dreamland_web
- git pull
- kill -9 $SSH_AGENT_PID
- name: update_website
commands:
- /usr/bin/node /var/www/dreamland_web/website.js/main.js /home/dreamland/runtime
- name: update_helps
commands:
- /usr/bin/node /var/www/dreamland_web/help.js/help.js /var/www/dreamland_web/static/help
- name: restart_searcher
commands:
- sudo systemctl restart dreamland-searcher.service
- name: discord_failure
commands:
- >
echo "{\"embeds\":[{\"color\": 13632027,\"description\":\"Latest dreamland_web failed to build, what have you done, mate?\n\",\"title\":\"Deployment failed!\"}], \"username\":\"Drone Bot\", \"avatar_url\": \"https://docs.drone.io/logo.svg\"}" \
| /home/dreamland/runtime/bin/idiscord-code
when:
status:
- failure
- name: discord_success
commands:
- >
echo "{\"embeds\":[{\"color\": 8311585,\"description\":\"DreamLand website is updated, enjoy!\n\",\"title\":\"Deployment successful\"}], \"username\":\"Drone Bot\", \"avatar_url\": \"https://docs.drone.io/logo.svg\"}" \
| /home/dreamland/runtime/bin/idiscord-code
when:
status:
- success
trigger:
branch:
- master
event:
- push