From f34ca830fa9108f6b8255eeb8391621f91068ae0 Mon Sep 17 00:00:00 2001 From: Ashhhleyyy Date: Sat, 13 Aug 2022 16:38:02 +0100 Subject: [PATCH] feat(ci): add drone workflow --- .drone.yml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .drone.yml diff --git a/.drone.yml b/.drone.yml new file mode 100644 index 0000000..f798cb2 --- /dev/null +++ b/.drone.yml @@ -0,0 +1,31 @@ +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: Check formatting + image: node-pnpm:16-alpine + commands: + - pnpm format:check +- name: Build site + image: node-pnpm:16-alpine + commands: + - pnpm build +- name: Deploy site + image: alpine + commands: + - apk add curl ca-certificates zip + - cd dist && zip -r ../deploy.zip * && cd .. + - 'curl --fail --upload-file deploy.zip -H "Authorization: token $GITEA_TOKEN" https://git.ashhhleyyy.dev/api/packages/ash/generic/doodly/$DRONE_COMMIT_SHA/doodly.zip' + environment: + GITEA_TOKEN: + from_secret: GITEA_TOKEN +trigger: + event: [push] + branch: [main]