CI.. or something
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed

This commit is contained in:
Neil Hanlon 2022-11-11 16:14:34 -05:00
parent 77b83ebf75
commit a5633fb9fa
Signed by: neil
GPG Key ID: 705BC21EC3C70F34
3 changed files with 44 additions and 0 deletions

1
.gitignore vendored
View File

@ -1,2 +1,3 @@
public/ public/
resources/ resources/
pages.git/

20
.woodpecker.yml Normal file
View File

@ -0,0 +1,20 @@
---
branches: main
clone:
git:
image: woodpeckerci/plugin-git
settings:
recursive: true
pipeline:
build:
image: registry.gitlab.com/pages/hugo/hugo_extended:latest
commands:
- hugo
publish:
image: ubuntu-latest
commands:
- ./deploy.sh

23
deploy.sh Normal file
View File

@ -0,0 +1,23 @@
#!/bin/bash -ex
REMOTE=$(git remote get-url origin)
rm -fr pages.git
mkdir pages.git
( cd pages.git && git init -b pages )
rsync -av public/* pages.git
cat << EOF > pages.git/.domains
neilhanlon.me
neilhanlon.com
hanlon.ninja
thepotato.tech
EOF
cd pages.git
git add -A
git commit -m "Deployment at $(date -u -Is)"
git remote add origin $REMOTE
git push -f origin pages