Add dev site deploy to Drone CI config
This commit is contained in:
parent
11bdcf8eae
commit
288c6ae2eb
38
.drone.yml
38
.drone.yml
@ -1,6 +1,7 @@
|
||||
kind: pipeline
|
||||
name: default
|
||||
steps:
|
||||
# ============ BUILD STEPS ===============
|
||||
- name: build-prod
|
||||
image: node:14
|
||||
commands:
|
||||
@ -8,6 +9,8 @@ steps:
|
||||
- npm install @ionic/cli
|
||||
- ./node_modules/.bin/ionic build --prod
|
||||
- tar czf build.tar.gz www
|
||||
|
||||
# =============== RELEASE ===============
|
||||
- name: release
|
||||
image: plugins/gitea-release
|
||||
settings:
|
||||
@ -18,6 +21,25 @@ steps:
|
||||
title: ${DRONE_TAG}
|
||||
when:
|
||||
event: tag
|
||||
|
||||
# =============== DEPLOY TO DEV SITE ===============
|
||||
- name: copy artifacts to staging site
|
||||
image: appleboy/drone-scp
|
||||
settings:
|
||||
host:
|
||||
from_secret: dev_site_host
|
||||
username:
|
||||
from_secret: dev_site_user
|
||||
key:
|
||||
from_secret: dev_site_key
|
||||
port: 22
|
||||
source: build.tar.gz
|
||||
target: /etc/glmdev/noded
|
||||
when:
|
||||
event: promote
|
||||
target: staging
|
||||
|
||||
# =============== NOTIFICATIONS ===============
|
||||
- name: send success notifications
|
||||
image: plugins/webhook
|
||||
settings:
|
||||
@ -45,18 +67,4 @@ steps:
|
||||
"priority": 6
|
||||
}
|
||||
when:
|
||||
status: failure
|
||||
# - name: promote Flitter docs
|
||||
# image: plugins/downstream
|
||||
# settings:
|
||||
# server: https://ci.garrettmills.dev
|
||||
# token:
|
||||
# from_secret: drone_token
|
||||
# fork: false
|
||||
# last_successful: true
|
||||
# deploy: production
|
||||
# repositories:
|
||||
# - flitter/docs@master
|
||||
# when:
|
||||
# status: success
|
||||
# event: tag
|
||||
status: failure
|
Loading…
Reference in New Issue
Block a user