Add Drone config
This commit is contained in:
parent
13e87f67b4
commit
b90c47a608
40
.drone.yml
Normal file
40
.drone.yml
Normal file
@ -0,0 +1,40 @@
|
||||
---
|
||||
kind: pipeline
|
||||
name: deploy to docker container
|
||||
steps:
|
||||
- name: remove .git
|
||||
image: debian:buster
|
||||
commands:
|
||||
- rm -r .git/
|
||||
- name: php syntax check
|
||||
image: php:8.0.10-cli
|
||||
commands:
|
||||
- for f in $(find /drone -name '*.php'); do php -l "$f"; done
|
||||
- name: docker cp deploy
|
||||
image: 3wordchant/docker-cp-deploy:latest
|
||||
settings:
|
||||
host: smol-wp.autonomic.zone
|
||||
service: beta_autonomic_zone_app
|
||||
source: .
|
||||
dest: /var/www/html/wp-content/themes/autonomic-block-theme
|
||||
deploy_key:
|
||||
from_secret: drone_ssh_smol-wp.autonomic.zone
|
||||
depends_on:
|
||||
- php syntax check
|
||||
- name: notify on failure
|
||||
image: plugins/slack
|
||||
settings:
|
||||
username: comradebritney
|
||||
channel: clients.shaping-our-lives
|
||||
template: "{{repo.owner}}/{{repo.name}} build failed: {{build.link}}. Last commit by @{{build.author}}"
|
||||
webhook:
|
||||
from_secret: rc_builds_url
|
||||
depends_on:
|
||||
- docker cp deploy
|
||||
when:
|
||||
status:
|
||||
- failure
|
||||
|
||||
trigger:
|
||||
branch:
|
||||
- main
|
Loading…
Reference in New Issue
Block a user