TEW-0x00/.drone.yml
surtur b5e847c337
All checks were successful
continuous-integration/drone/push Build is passing
fix2: site not getting deployed
* solve it by running the deploy script in freshly spawned `bash`
2020-03-25 23:10:42 +01:00

54 lines
1.4 KiB
YAML

---
kind: pipeline
type: docker
name: deploy
steps:
- name: ssh-deploy
pull: if-not-exists
image: appleboy/drone-ssh:latest
settings:
host:
from_secret: tew_host
username:
from_secret: tew_user
password:
from_secret: tew_passwd
script_stop: true
script:
- eval $(ssh-agent)
- ssh-add ~/.ssh/overlord
- cd ~/tew_0x00
- git pull
- bash ./deploy
---
kind: pipeline
name: notifications-deploy
platform:
os: linux
arch: amd64
clone:
disable: true
trigger:
status:
- success
- failure
depends_on:
- deploy
steps:
- name: discord
pull: always
image: appleboy/drone-discord:1.2.4
settings:
message: "{{#success build.status}} ✅ [Build #{{build.number}}]({{build.link}}) of `{{repo.name}}` has been successfully deployed.\nevent: **`{{build.event}}`**\ncommit [`${DRONE_COMMIT_SHA:0:7}`](https://git.dotya.ml/${DRONE_REPO}/commit/${DRONE_COMMIT_SHA}) by {{commit.author}} on `{{commit.branch}}`\n {{else}} ❌ [Build #{{build.number}}]({{build.link}}) of `{{repo.name}}` failed to deploy.\nevent: **`${DRONE_BUILD_EVENT}`**\ncommit [`${DRONE_COMMIT_SHA:0:7}`](https://git.dotya.ml/${DRONE_REPO}/commit/${DRONE_COMMIT_SHA}) by {{commit.author}} on `{{commit.branch}}`\n{{/success}}\n"
webhook_id:
from_secret: discord_webhook_id
webhook_token:
from_secret: discord_webhook_token