ceiba-scores/.drone.yml

133 lines
3.3 KiB
YAML
Raw Normal View History

2022-03-30 00:08:30 +02:00
---
# drone encrypt weko/scores.ceiba-conseil.com $REGISTRY_PASSWORD
kind: secret
name: REGISTRY_PASSWORD
data: BW8D91fKNJuWWF5k5F/CNi8GIQvmNEUocqPJJ+N57qxQ06y+G9q715PBFpys5BTKUQHPQqSd7Q6MhWpsOc5Ttn/gtCX1tbGrAqsFrEec
---
# drone encrypt weko/scores.ceiba-conseil.com $REGISTRY_USER
kind: secret
name: REGISTRY_USER
data: dlboI6U0j0jZxVQiF62p9lQkpFBg7M4QtiD6K7K3NtQmkw==
---
# drone encrypt weko/scores.ceiba-conseil.com "{\"auths\":{\"https://registry.weko.io\":{\"auth\":\"$(echo -n "$REGISTRY_USER:$REGISTRY_PASSWORD" | base64)\",\"email\":\"$REGISTRY_USER\"}}}"
kind: secret
name: REGISTRY_CONFIG
data: B0svjVRqxyDJE+MmSPPCU2hWbBzTjYHS6CnV6IAzGxrQPVNbGmEqoCWkBsG6tUFhL3JcU+fYEidV+RVHTRpYumbDWTXlBSz0q3BVsfqxvgWb2JgpvO7/X3rIxCZwECMMMm7nyRubsOeFDzFh9ic1cU4Bw2DTA+L65lWGiEGME/KqCi6yKy56KjmAC8kAoJ9ifw++KsGytvZjPI68+bbWpRFTAuwWU3SDv12y
---
# drone encrypt weko/scores.ceiba-conseil.com $DIRECTUS_URL
kind: secret
name: DIRECTUS_URL
data: Z1mUl3LdiVP6vClaVeA56nTafKHIevYaRKqqYDKycN5im+M93XvrZbK995EDreb4cttMD1jMmJaq3NQ=
---
# drone encrypt weko/scores.ceiba-conseil.com $DIRECTUS_TOKEN
kind: secret
name: DIRECTUS_TOKEN
data: C4N8jh2kDORa5vo2mqOcqbBLLBXdcnHNDq9sK6+R9gzemeyzLp3K7ENw5ZibVYAJ2VEYylQr9zvHFeFE
# ---
# 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
# volumes:
# - name: hugo-theme-lowtech_node_modules
# path: /drone/src/themes/hugo-theme-lowtech/node_modules
# # 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
# image: jakejarvis/hugo-extended
# commands:
# - hugo --minify --environment production
#
# - name: typo
# image: node:current-alpine
# volumes:
# - name: hugo-theme-lowtech_node_modules
# path: /drone/src/themes/hugo-theme-lowtech/node_modules
# commands:
# - node themes/hugo-theme-lowtech/scripts/typo
#
# - name: push docker image on registry
# image: plugins/docker
# settings:
# username:
# from_secret: REGISTRY_USER
# password:
# from_secret: REGISTRY_PASSWORD
# repo: registry.weko.io/sisa-urfe_fr
# registry: registry.weko.io
# tags:
# - latest
#
# image_pull_secrets:
# - REGISTRY_CONFIG
#
# volumes:
# - name: hugo-theme-lowtech_node_modules
# host:
# path: /tmp/drone/cache/weko/scores.ceiba-conseil.com/themes/hugo-theme-lowtech
---
kind: pipeline
type: docker
name: staging
platform:
os: linux
arch: arm64
steps:
- name: install npm
image: node:current-alpine
volumes:
- name: node_modules
path: /drone/src/node_modules
commands:
- npm i
- npm run fetchData
- npm run lint
- npm run build
- name: push docker image on registry
image: plugins/docker
settings:
username:
from_secret: REGISTRY_USER
password:
from_secret: REGISTRY_PASSWORD
repo: registry.weko.io/scores_ceiba
registry: registry.weko.io
tags:
- staging
image_pull_secrets:
- REGISTRY_CONFIG
volumes:
- name: node_modules
host:
path: /tmp/drone/cache/weko/scores.ceiba-conseil.com/node_modules