added drone config file

This commit is contained in:
sunda 2022-03-30 11:40:48 +02:00
parent 30089e6ee6
commit 31c9e1aada

65
.drone.yml Normal file
View File

@ -0,0 +1,65 @@
kind: pipeline
name: default
steps:
- name: Build jekyll
image: jekyll/jekyll:latest
commands:
- "JEKYLL_ENV=production jekyll build"
- name: Build parcel
image: node:lts
commands:
- yarn
- "npx parcel build src/index.js -d ./_site/assets/js"
volumes:
- name: cache
path: /drone/src/node_modules
- name: Deploy to staging
image: drillster/drone-rsync
settings:
settings:
user:
from_secret: shikoku_ssh_user
key:
from_secret: shikoku_ssh_key
hosts:
from_secret: shikoku_hostname
source: ./public/*
target: ~/sites/staging.reclaimfutures.org
port:
from_secret: shikoku_ssh_port
secrets: [shikoku_ssh_key, shikoku_hostname, shikoku_ssh_user, shikoku_ssh_port]
when:
branch:
- dev
event:
- push
- custom
- name: Deploy to production
image: drillster/drone-rsync
settings:
settings:
user:
from_secret: shikoku_ssh_user
key:
from_secret: shikoku_ssh_key
hosts:
from_secret: shikoku_hostname
source: ./public/*
target: ~/sites/reclaimfutures.org
port:
from_secret: shikoku_ssh_port
secrets: [shikoku_ssh_key, shikoku_hostname, shikoku_ssh_user, shikoku_ssh_port]
when:
branch:
- main
event:
- push
- custom
volumes:
- name: cache
host:
path: /tmp/drone/cache/node_modules