|
|
@ -59,6 +59,43 @@ steps:
|
|
|
|
event: promote
|
|
|
|
event: promote
|
|
|
|
target: staging
|
|
|
|
target: staging
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# =============== DEPLOY TO PROD SITE ===============
|
|
|
|
|
|
|
|
- name: copy artifacts to production site
|
|
|
|
|
|
|
|
image: appleboy/drone-scp
|
|
|
|
|
|
|
|
settings:
|
|
|
|
|
|
|
|
host:
|
|
|
|
|
|
|
|
from_secret: prod_site_host
|
|
|
|
|
|
|
|
username:
|
|
|
|
|
|
|
|
from_secret: prod_site_user
|
|
|
|
|
|
|
|
key:
|
|
|
|
|
|
|
|
from_secret: prod_site_key
|
|
|
|
|
|
|
|
port: 22
|
|
|
|
|
|
|
|
source: build.tar.gz
|
|
|
|
|
|
|
|
target: /etc/glmdev/noded-prod
|
|
|
|
|
|
|
|
when:
|
|
|
|
|
|
|
|
event: promote
|
|
|
|
|
|
|
|
target: staging
|
|
|
|
|
|
|
|
- name: deploy artifacts on staging site
|
|
|
|
|
|
|
|
image: appleboy/drone-ssh
|
|
|
|
|
|
|
|
settings:
|
|
|
|
|
|
|
|
host:
|
|
|
|
|
|
|
|
from_secret: prod_site_host
|
|
|
|
|
|
|
|
username:
|
|
|
|
|
|
|
|
from_secret: prod_site_user
|
|
|
|
|
|
|
|
key:
|
|
|
|
|
|
|
|
from_secret: prod_site_key
|
|
|
|
|
|
|
|
port: 22
|
|
|
|
|
|
|
|
script:
|
|
|
|
|
|
|
|
- cd /etc/glmdev/noded-prod
|
|
|
|
|
|
|
|
- rm -rf www
|
|
|
|
|
|
|
|
- tar xzf build.tar.gz
|
|
|
|
|
|
|
|
- cd www
|
|
|
|
|
|
|
|
- sed -i 's/<base href="\\/" \\/>/<base href="\\/i\\/"\\/>/' index.html
|
|
|
|
|
|
|
|
- sed -i 's/Ionic App/Noded/' index.html
|
|
|
|
|
|
|
|
when:
|
|
|
|
|
|
|
|
event: promote
|
|
|
|
|
|
|
|
target: production
|
|
|
|
|
|
|
|
|
|
|
|
# =============== NOTIFICATIONS ===============
|
|
|
|
# =============== NOTIFICATIONS ===============
|
|
|
|
- name: send success notifications
|
|
|
|
- name: send success notifications
|
|
|
|
image: plugins/webhook
|
|
|
|
image: plugins/webhook
|
|
|
|