brainsteam.co.uk/.drone.yml

57 lines
1.5 KiB
YAML
Raw Normal View History

2020-12-28 11:54:51 +00:00
kind: pipeline
name: update_website
2020-12-28 13:24:52 +00:00
steps:
2020-12-28 13:22:03 +00:00
- name: hugo_build
2020-12-28 11:54:51 +00:00
image: alombarte/hugo
when:
branch:
- main
2020-12-28 11:54:51 +00:00
commands:
2020-12-28 11:56:31 +00:00
- git submodule init
2020-12-28 11:57:19 +00:00
- git submodule update
2020-12-28 11:55:42 +00:00
- cd brainsteam
2020-12-28 12:09:39 +00:00
- hugo
2021-12-21 14:30:28 +00:00
# - cd ../
# - git fetch origin public && git checkout public
# - cp -r brainsteam/public new_files
# - rm -rf brainsteam/
# - cp -Tr new_files/ ./
# - rm -rf new_files/
2020-12-28 13:22:03 +00:00
- name: hugo_publish
2021-12-21 14:30:28 +00:00
image: alpine:3.12.3
2021-12-21 12:21:34 +00:00
image: appleboy/drone-git-push
2021-12-21 14:30:28 +00:00
# settings:
# remote_name: origin
# branch: public
# local_ref: public
# commit: true
# commit_message: update build from hugo
# author_name: DroneCI
when:
branch:
- main
environment:
INPUT_HASHFILE: hashes.sha256
INPUT_HASHTYPE: sha256
INPUT_PROTOCOL: ftp
INPUT_HOST: sv7.byethost7.org
2021-12-21 14:33:45 +00:00
INPUT_DESTINATION: /
2021-12-21 14:30:28 +00:00
INPUT_SOURCE: brainsteam/public
INPUT_USERNAME:
from_secret: FTP_USERNAME
INPUT_PASSWORD:
from_secret: FTP_PASSWORD
FTP_HOSTNAME: sv7.byethost7.org
commands:
- apk add lftp
# - cd brainsteam
# - lftp -e "mirror -R ./public /" -u $FTP_USERNAME,$FTP_PASSWORD $FTP_HOSTNAME
2021-12-25 11:09:34 +00:00
- sh sync.sh
- name: webmention_check
image: 3apaxicom/npx
when:
branch:
- main
commands:
- npx webmention https://brainsteam.co.uk/index.xml --limit 1 --send