chs/.drone.yml
Ashhhleyyy d182565f0a
Some checks failed
continuous-integration/drone/push Build is failing
fix(ci): install musl-dev
2022-11-02 15:06:59 +00:00

35 lines
812 B
YAML

kind: pipeline
type: docker
name: Build
platform:
os: linux
arch: arm64
steps:
- name: Install dependencies
image: node-pnpm:16-alpine
commands:
- pnpm install --frozen-lockfile
- name: Build frontend
image: node-pnpm:16-alpine
commands:
- pnpm build
- name: Build server binary
image: rust:1.64.0-alpine
commands:
- apk add --no-cache musl-dev
- cargo build --release
- name: Deploy site
image: alpine
commands:
- apk add curl ca-certificates zip
- cd dist && zip -r ../deploy.zip * && cd ..
- 'curl --fail --upload-file target/release/chs -H "Authorization: $GITEA_TOKEN" https://git.ashhhleyyy.dev/api/v1/packages/ash/generic/chs/$DRONE_COMMIT_SHA/chs'
environment:
GITEA_TOKEN:
from_secret: GITEA_TOKEN
trigger:
event: [push]
branch: [main]