2022-02-02 17:38:21 +01:00
|
|
|
---
|
2023-02-24 17:52:31 +01:00
|
|
|
# drone encrypt Weko/cremeaux $DIRECTUS_URL
|
2022-02-02 17:38:21 +01:00
|
|
|
kind: secret
|
|
|
|
name: DIRECTUS_URL
|
2023-02-24 17:52:31 +01:00
|
|
|
data: RDzjslPRJRwgL9qhzcq3wVeCN91hAbO6vwd1XFCJ/G4Pm44iASdNjdZ3QfGja6pg1TJ1FSmZZg==
|
2022-02-02 17:38:21 +01:00
|
|
|
|
|
|
|
---
|
2023-02-24 17:52:31 +01:00
|
|
|
# drone encrypt Weko/cremeaux $DIRECTUS_TOKEN
|
2022-02-02 17:38:21 +01:00
|
|
|
kind: secret
|
|
|
|
name: DIRECTUS_TOKEN
|
2023-02-24 17:52:31 +01:00
|
|
|
data: NHpX9VNOhcDrS4feXOVi1sL2K44yvdGk9m4CUlpUImqpJGZ8gPQDX+0pffXjhkv6EerRaUsYA6cVNZvY
|
2022-02-02 17:38:21 +01:00
|
|
|
|
2022-12-02 10:18:02 +01:00
|
|
|
---
|
2023-02-24 17:52:31 +01:00
|
|
|
# drone encrypt Weko/cremeaux $AWS_ACCESS_KEY_ID
|
2022-12-02 10:18:02 +01:00
|
|
|
kind: secret
|
|
|
|
name: STAGING_AWS_ACCESS_KEY_ID
|
2023-02-24 17:52:31 +01:00
|
|
|
data: E8jzEjG64MRSoRO6g5CSQnNmpnP6Ck2EwIhPNwyVuGudzFGT88UbQ8gppUV9vF9vAoKQ/NNC
|
2022-12-02 10:18:02 +01:00
|
|
|
|
|
|
|
---
|
2023-02-24 17:52:31 +01:00
|
|
|
# drone encrypt Weko/cremeaux $AWS_SECRET_ACCESS_KEY
|
2022-12-02 10:18:02 +01:00
|
|
|
kind: secret
|
|
|
|
name: STAGING_AWS_SECRET_ACCESS_KEY
|
2023-02-24 17:52:31 +01:00
|
|
|
data: 6Vvc4kHWpQlx+2MOd8V4MLFXjg5EhIwDijQoQIdkhjwXaoIHjUlQdfSqidkE1JYKHSoL7k3/m/NKT4l+oTXv6MVDWcm2mWX5pnIA08PDHifgMEVDNUdgdbm3qpo=
|
2022-12-02 10:18:02 +01:00
|
|
|
|
|
|
|
---
|
2023-02-24 17:52:31 +01:00
|
|
|
# drone encrypt Weko/cremeaux $AWS_ACCESS_KEY_ID
|
2022-12-02 10:18:02 +01:00
|
|
|
kind: secret
|
|
|
|
name: PRODUCTION_AWS_ACCESS_KEY_ID
|
2023-02-24 17:52:31 +01:00
|
|
|
data: rQ4HtHyB7cMd024W6/vIeDNSHb5oHunINlq5Zvg/U1qWp/d0XnmgO0ArOg43A+XTyX5bHmFJ
|
2022-12-02 10:18:02 +01:00
|
|
|
|
|
|
|
---
|
2023-02-24 17:52:31 +01:00
|
|
|
# drone encrypt Weko/cremeaux $AWS_SECRET_ACCESS_KEY
|
2022-12-02 10:18:02 +01:00
|
|
|
kind: secret
|
|
|
|
name: PRODUCTION_AWS_SECRET_ACCESS_KEY
|
2023-02-24 17:52:31 +01:00
|
|
|
data: ep+PGU9itGdRKZkmPlqSdalU8HRZQLXP4wAS8y0jJc9TQIrNAxtYeR6Bpp3d9VN/gtS2pcpquZaF0beP3Zs4o8clcUuqM5ZIi9AxlsUcnKHs++6ihjy8ObDXAxk=
|
2022-12-02 10:18:02 +01:00
|
|
|
|
2022-02-02 17:38:21 +01:00
|
|
|
---
|
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
|
|
|
name: prod
|
|
|
|
|
|
|
|
platform:
|
|
|
|
os: linux
|
|
|
|
arch: arm64
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: install submodule
|
|
|
|
image: drone/git
|
|
|
|
commands:
|
|
|
|
- git submodule update --init
|
|
|
|
|
|
|
|
- name: install npm
|
|
|
|
image: node:current-alpine
|
2022-02-03 11:03:23 +01:00
|
|
|
volumes:
|
|
|
|
- name: hugo-theme-lowtech_node_modules
|
|
|
|
path: /drone/src/themes/hugo-theme-lowtech/node_modules
|
2022-02-02 17:38:21 +01:00
|
|
|
environment:
|
|
|
|
DIRECTUS_URL:
|
|
|
|
from_secret: DIRECTUS_URL
|
|
|
|
DIRECTUS_TOKEN:
|
|
|
|
from_secret: DIRECTUS_TOKEN
|
|
|
|
commands:
|
|
|
|
- (cd themes/hugo-theme-lowtech && npm i)
|
|
|
|
- node scripts/directus-to-markdown/index.js
|
|
|
|
|
|
|
|
- name: build website
|
2022-12-02 10:18:02 +01:00
|
|
|
image: klakegg/hugo:0.101.0-ext-debian-ci
|
2022-12-02 13:11:51 +01:00
|
|
|
volumes:
|
|
|
|
- name: hugo-resources
|
|
|
|
path: /drone/src/resources
|
2022-02-02 17:38:21 +01:00
|
|
|
commands:
|
|
|
|
- hugo --minify --environment production
|
|
|
|
|
|
|
|
- name: typo
|
|
|
|
image: node:current-alpine
|
2022-02-03 11:03:23 +01:00
|
|
|
volumes:
|
|
|
|
- name: hugo-theme-lowtech_node_modules
|
|
|
|
path: /drone/src/themes/hugo-theme-lowtech/node_modules
|
2022-02-02 17:38:21 +01:00
|
|
|
commands:
|
|
|
|
- node themes/hugo-theme-lowtech/scripts/typo
|
|
|
|
|
2022-12-02 10:18:02 +01:00
|
|
|
- name: deploy
|
|
|
|
image: klakegg/hugo:0.101.0-ext-debian-ci
|
|
|
|
environment:
|
|
|
|
AWS_ACCESS_KEY_ID:
|
|
|
|
from_secret: PRODUCTION_AWS_ACCESS_KEY_ID
|
|
|
|
AWS_SECRET_ACCESS_KEY:
|
|
|
|
from_secret: PRODUCTION_AWS_SECRET_ACCESS_KEY
|
|
|
|
commands:
|
|
|
|
- hugo deploy --environment production
|
|
|
|
|
2023-01-11 18:05:18 +01:00
|
|
|
- name: notify
|
2023-01-13 15:42:42 +01:00
|
|
|
image: plugins/matrix@sha256:f1affb31b0c86963c97c6f976fa0dcb3cc84272057fd8558d609d28b3064bd7f
|
2023-01-11 18:05:18 +01:00
|
|
|
settings:
|
|
|
|
homeserver: https://converser.eu
|
2023-01-13 15:42:42 +01:00
|
|
|
roomid: "QwOITmkKxRJJyCSDOZ:converser.eu"
|
|
|
|
userid: "resilien:converser.eu"
|
2023-01-11 18:05:18 +01:00
|
|
|
accesstoken:
|
2023-01-13 15:42:42 +01:00
|
|
|
from_secret: MATRIX_ACCESSTOKEN
|
2023-01-11 18:05:18 +01:00
|
|
|
when:
|
|
|
|
status: [ failure ]
|
|
|
|
|
2022-02-03 11:03:23 +01:00
|
|
|
volumes:
|
|
|
|
- name: hugo-theme-lowtech_node_modules
|
|
|
|
host:
|
|
|
|
path: /tmp/drone/cache/weko/cremeaux/themes/hugo-theme-lowtech
|
2022-12-02 13:11:51 +01:00
|
|
|
- name: hugo-resources
|
|
|
|
host:
|
|
|
|
path: /tmp/drone/cache/weko/cremeaux/resources
|
2022-02-02 17:38:21 +01:00
|
|
|
|
|
|
|
---
|
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
|
|
|
name: staging
|
|
|
|
|
|
|
|
platform:
|
|
|
|
os: linux
|
|
|
|
arch: arm64
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: install submodule
|
|
|
|
image: drone/git
|
|
|
|
commands:
|
|
|
|
- git submodule update --init
|
|
|
|
|
|
|
|
- name: install npm
|
|
|
|
image: node:current-alpine
|
2022-02-03 11:03:23 +01:00
|
|
|
volumes:
|
|
|
|
- name: hugo-theme-lowtech_node_modules
|
|
|
|
path: /drone/src/themes/hugo-theme-lowtech/node_modules
|
2022-02-02 17:38:21 +01:00
|
|
|
environment:
|
|
|
|
DIRECTUS_URL:
|
|
|
|
from_secret: DIRECTUS_URL
|
|
|
|
DIRECTUS_TOKEN:
|
|
|
|
from_secret: DIRECTUS_TOKEN
|
|
|
|
commands:
|
|
|
|
- (cd themes/hugo-theme-lowtech && npm i)
|
|
|
|
- DRAFT=true node scripts/directus-to-markdown/index.js
|
|
|
|
|
|
|
|
- name: build website
|
2022-12-02 10:18:02 +01:00
|
|
|
image: klakegg/hugo:0.101.0-ext-debian-ci
|
2022-12-02 13:11:51 +01:00
|
|
|
volumes:
|
|
|
|
- name: hugo-resources
|
|
|
|
path: /drone/src/resources
|
2022-02-02 17:38:21 +01:00
|
|
|
commands:
|
|
|
|
- hugo --minify --buildDrafts --buildFuture --environment staging
|
|
|
|
|
|
|
|
- name: typo
|
|
|
|
image: node:current-alpine
|
2022-02-03 11:03:23 +01:00
|
|
|
volumes:
|
|
|
|
- name: hugo-theme-lowtech_node_modules
|
|
|
|
path: /drone/src/themes/hugo-theme-lowtech/node_modules
|
2022-02-02 17:38:21 +01:00
|
|
|
commands:
|
|
|
|
- node themes/hugo-theme-lowtech/scripts/typo
|
|
|
|
|
2022-12-02 10:18:02 +01:00
|
|
|
- name: deploy
|
|
|
|
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:
|
|
|
|
- hugo deploy --environment staging
|
|
|
|
|
2022-02-03 11:03:23 +01:00
|
|
|
volumes:
|
|
|
|
- name: hugo-theme-lowtech_node_modules
|
|
|
|
host:
|
|
|
|
path: /tmp/drone/cache/weko/cremeaux/themes/hugo-theme-lowtech
|
2022-12-02 13:11:51 +01:00
|
|
|
- name: hugo-resources
|
|
|
|
host:
|
|
|
|
path: /tmp/drone/cache/weko/cremeaux/resources
|