feat(Drone): Configure staging deploy

This commit is contained in:
Simon 2022-07-19 14:21:55 +02:00
parent 84528457ac
commit 9c8e96feaa
1 changed files with 32 additions and 15 deletions

View File

@ -1,21 +1,33 @@
--- ---
kind: pipeline # drone encrypt weko/sisa-urfe_fr $AWS_ACCESS_KEY_ID
type: docker kind: secret
name: production name: STAGING_AWS_ACCESS_KEY_ID
data: Fj/s8kHdQ4V4YQJLqHNCdtIuPeTXQvRhcqZdJhD+fqvstpHxlARinrp2aB0pzRPmbG27u+Gp
platform: ---
os: linux # drone encrypt weko/jarnat $AWS_SECRET_ACCESS_KEY
arch: arm64 kind: secret
name: STAGING_AWS_SECRET_ACCESS_KEY
data: cZ9+WkF1Q70ckB8ruLEcsKxeTw/sw33D7lMtpmTVjnojcLqUoOHx1arTzjtTSMrs7qXXOm6/xgqAcRqh1RPCRfW1RdVdeGHE84MQyTaU0ob+frzH8lNxCH+VMF0=
steps: # ---
- name: build # kind: pipeline
image: klakegg/hugo:0.101.0-ext-debian-ci # type: docker
commands: # name: production
- hugo --minify --environment production
- name: deploy # platform:
image: klakegg/hugo:0.101.0-ext-debian-ci # os: linux
commands: # arch: arm64
- hugo deploy --target=production
# steps:
# - name: build
# image: klakegg/hugo:0.101.0-ext-debian-ci
# commands:
# - hugo --minify --environment production
# - name: deploy
# image: klakegg/hugo:0.101.0-ext-debian-ci
# commands:
# - hugo deploy --target=production
--- ---
kind: pipeline kind: pipeline
@ -33,5 +45,10 @@ steps:
- hugo --minify --buildDrafts --buildFuture --environment staging - hugo --minify --buildDrafts --buildFuture --environment staging
- name: deploy - name: deploy
image: klakegg/hugo:0.101.0-ext-debian-ci image: klakegg/hugo:0.101.0-ext-debian-ci
environment:
AWS_ACCESS_KEY_ID:
from_secret: STAGING_AWS_ACCESS_KEY_ID
AWS_SECRET_ACCESS_KEY:
from_secret: STAGING_AWS_SECRET_ACCESS_KEY
commands: commands:
- hugo deploy --target=staging - hugo deploy --target=staging