rf-web/.drone.yml

70 lines
1.5 KiB
YAML
Raw Permalink Normal View History

2022-03-30 09:40:48 +00:00
kind: pipeline
name: default
steps:
- name: Build jekyll
image: jekyll/jekyll:latest
user: root
environment:
JEKYLL_UID: 1000
JEKYLL_GID: 1000
2022-03-30 09:40:48 +00:00
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