mirror of
https://github.com/lemeow125/Notes.git
synced 2025-04-19 16:31:25 +08:00
Compare commits
No commits in common. "c20c16b579473dd12e6784a1f42df445cc2b4f2a" and "ada7309184b17300df52aeb56b90fedd50ca5ed2" have entirely different histories.
c20c16b579
...
ada7309184
2 changed files with 12 additions and 39 deletions
|
@ -4,6 +4,15 @@ labels:
|
|||
steps:
|
||||
- name: build
|
||||
image: docker
|
||||
when:
|
||||
- branch: master
|
||||
event: push
|
||||
commands:
|
||||
- docker build -t "$REGISTRY_IMAGE_TAG" .
|
||||
- echo "$FORGEJO_REGISTRY_PASSWORD" | docker login "$FORGEJO_REGISTRY_URL" --password-stdin -u "$FORGEJO_REGISTRY_USERNAME"
|
||||
- docker push "$REGISTRY_IMAGE_TAG"
|
||||
volumes:
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
environment:
|
||||
FORGEJO_REGISTRY_URL:
|
||||
from_secret: FORGEJO_REGISTRY_URL
|
||||
|
@ -13,25 +22,3 @@ steps:
|
|||
from_secret: FORGEJO_REGISTRY_PASSWORD
|
||||
REGISTRY_IMAGE_TAG:
|
||||
from_secret: REGISTRY_IMAGE_TAG
|
||||
commands:
|
||||
- docker build -t "$REGISTRY_IMAGE_TAG" .
|
||||
- echo "$FORGEJO_REGISTRY_PASSWORD" | docker login "$FORGEJO_REGISTRY_URL" --password-stdin -u "$FORGEJO_REGISTRY_USERNAME"
|
||||
- docker push "$REGISTRY_IMAGE_TAG"
|
||||
volumes:
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
- name: discord
|
||||
image: appleboy/drone-discord
|
||||
settings:
|
||||
webhook_id:
|
||||
from_secret: DISCORD_WEBHOOK_ID
|
||||
webhook_token:
|
||||
from_secret: DISCORD_WEBHOOK_TOKEN
|
||||
message: >
|
||||
{{#success build.status}}
|
||||
{{repo.name}} build #{{build.number}} {{build.status}}
|
||||
{{/success}}
|
||||
depends_on: build
|
||||
|
||||
when:
|
||||
- branch: master
|
||||
event: push
|
||||
|
|
|
@ -1,29 +1,15 @@
|
|||
steps:
|
||||
- name: deploy
|
||||
image: node:18-alpine
|
||||
when:
|
||||
- branch: master
|
||||
event: push
|
||||
environment:
|
||||
CLOUDFLARE_ACCOUNT_ID:
|
||||
from_secret: CLOUDFLARE_ACCOUNT_ID
|
||||
CLOUDFLARE_API_TOKEN:
|
||||
from_secret: CLOUDFLARE_API_TOKEN
|
||||
commands:
|
||||
- apk add git
|
||||
- npm install --save-dev
|
||||
- npm run build
|
||||
- npx wrangler pages deploy "./build/" --project-name blog --branch master --commit-dirty
|
||||
- name: discord
|
||||
image: appleboy/drone-discord
|
||||
settings:
|
||||
webhook_id:
|
||||
from_secret: DISCORD_WEBHOOK_ID
|
||||
webhook_token:
|
||||
from_secret: DISCORD_WEBHOOK_TOKEN
|
||||
message: >
|
||||
{{#success build.status}}
|
||||
{{repo.name}} deployment #{{build.number}} {{build.status}}
|
||||
{{/success}}
|
||||
depends_on: deploy
|
||||
|
||||
when:
|
||||
- branch: master
|
||||
event: push
|
||||
|
|
Loading…
Add table
Reference in a new issue