2022-07-04 20:03:22 +00:00
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
|
|
|
name: Build
|
|
|
|
|
2022-07-04 20:07:42 +00:00
|
|
|
platform:
|
|
|
|
os: linux
|
|
|
|
arch: arm64
|
|
|
|
|
2022-07-04 20:03:22 +00:00
|
|
|
steps:
|
2022-07-05 13:55:45 +00:00
|
|
|
- name: Install dependencies
|
2022-07-05 20:46:45 +00:00
|
|
|
image: node-pnpm:16-alpine
|
2022-07-04 20:03:22 +00:00
|
|
|
commands:
|
|
|
|
- pnpm install --frozen-lockfile
|
2022-07-05 13:55:45 +00:00
|
|
|
- name: Check formatting
|
2022-07-05 20:46:45 +00:00
|
|
|
image: node-pnpm:16-alpine
|
2022-07-05 13:55:45 +00:00
|
|
|
commands:
|
2022-07-04 20:03:22 +00:00
|
|
|
- pnpm format:check
|
2022-07-05 13:55:45 +00:00
|
|
|
- name: Build site
|
2022-07-05 20:46:45 +00:00
|
|
|
image: node-pnpm:16-alpine
|
2022-07-05 13:55:45 +00:00
|
|
|
commands:
|
|
|
|
- pnpm build
|
2022-07-05 09:45:31 +00:00
|
|
|
- name: Deploy site
|
|
|
|
image: alpine
|
|
|
|
commands:
|
|
|
|
- apk add curl ca-certificates zip
|
|
|
|
- cd dist && zip -r ../deploy.zip * && cd ..
|
2022-07-05 09:55:00 +00:00
|
|
|
- 'curl --fail -F file=@deploy.zip -H "Authorization: $DEPLOY_TOKEN" https://projects.ashhhleyyy.dev/chss'
|
2022-07-05 09:45:31 +00:00
|
|
|
environment:
|
|
|
|
DEPLOY_TOKEN:
|
|
|
|
from_secret: deploy_token
|
2022-07-04 20:03:22 +00:00
|
|
|
|
|
|
|
trigger:
|
|
|
|
event: [push]
|
|
|
|
branch: [main]
|