lib/.drone.yml

78 lines
1.6 KiB
YAML
Raw Normal View History

2022-11-29 16:37:23 +00:00
---
kind: pipeline
2022-11-29 16:37:23 +00:00
type: kubernetes
name: docs
2022-11-29 16:37:23 +00:00
metadata:
labels:
pod-security.kubernetes.io/audit: privileged
2022-11-29 16:37:23 +00:00
services:
- name: docker daemon
image: docker:dind
privileged: true
environment:
DOCKER_TLS_CERTDIR: ""
2021-03-29 16:42:45 +00:00
steps:
2022-11-29 16:37:23 +00:00
- name: typedoc build
image: node:18
2021-03-29 16:42:45 +00:00
commands:
2022-11-29 16:37:23 +00:00
- "npm add --global pnpm"
2021-03-29 16:42:45 +00:00
- pnpm i
2022-11-29 16:37:23 +00:00
- pnpm run docs:build
2021-09-21 18:42:06 +00:00
2022-11-29 16:37:23 +00:00
- name: container build
image: docker:latest
privileged: true
2021-09-21 18:42:06 +00:00
commands:
- "while ! docker stats --no-stream; do sleep 1; done"
2022-11-29 16:37:23 +00:00
- docker image build docs -t $DOCKER_REGISTRY/extollo/docs:latest
- docker push $DOCKER_REGISTRY/extollo/docs:latest
environment:
DOCKER_HOST: tcp://localhost:2375
DOCKER_REGISTRY:
from_secret: DOCKER_REGISTRY
- name: k8s rollout
image: bitnami/kubectl
2021-09-21 18:42:06 +00:00
commands:
2022-11-29 17:01:55 +00:00
- cd docs/deploy && kubectl apply -f .
2022-11-29 16:37:23 +00:00
- kubectl rollout restart -n extollo deployment/docs
2022-11-29 17:44:46 +00:00
---
kind: pipeline
type: kubernetes
name: npm
steps:
- name: node.js build
image: node:18
commands:
- "npm add --global pnpm"
- pnpm i
- pnpm build
- name: gitea release
image: plugins/gitea-release
settings:
api_key:
from_secret: GITEA_TOKEN
base_url: https://code.garrettmills.dev
checksum: md5
title: ${DRONE_TAG}
when:
event: tag
status: success
- name: npm release
image: plugins/npm
settings:
username: extollo_bot
password:
from_secret: NPM_PASSWORD
email: extollo@garrettmills.dev
when:
event: tag
status: success