gcg-website/.drone.yml

49 lines
1.1 KiB
YAML
Raw Normal View History

2023-01-14 09:07:12 +00:00
kind: pipeline
type: docker
name: website-build
platform:
os: linux
arch: amd64
steps:
2023-01-22 14:06:28 +01:00
- name: hugo build
2023-01-14 09:07:12 +00:00
image: plugins/hugo
settings:
2023-01-22 14:06:28 +01:00
hugo_version: 0.110.0
2023-01-14 09:07:12 +00:00
validate: false
extended: true
2023-01-22 14:06:28 +01:00
url: https://dev.cantorgymnasium.de
2023-01-14 09:07:12 +00:00
commands:
2023-01-22 14:06:28 +01:00
- apk add --update --no-cache tzdata git
2023-01-14 09:07:12 +00:00
- /bin/drone-hugo
- find public -type f -regex '.*\.\(htm\|html\|txt\|text\|js\|css\)$' -print0 | xargs -0 gzip -9 -f -k
- git init public
2023-01-22 14:06:28 +01:00
- name: push public
2023-01-14 09:07:12 +00:00
image: appleboy/drone-git-push
settings:
branch: pages
remote:
from_secret: drone_remote
force: true
commit: true
2023-01-22 14:06:28 +01:00
commit_message: "[ci] website update"
2023-01-14 09:07:12 +00:00
path: public
author_name: GCG.Admin
author_email: admin@cantor-gymnasium.de
2023-01-22 14:06:28 +01:00
- name: notification
2023-01-14 09:07:12 +00:00
image: appleboy/drone-telegram
settings:
token:
from_secret: telegram_token
to:
from_secret: telegram_room_id
when:
status:
- success
- failure
trigger:
branch:
- master