feat: new deploy.yml

This commit is contained in:
Filippo Ferrari 2024-02-16 22:48:55 +01:00
parent b6b0c890df
commit 91e57a4e40

View file

@ -1,4 +1,4 @@
name: Deploy to Github Pages
name: Deploy to Home Server
on:
push:
@ -11,8 +11,6 @@ jobs:
runs-on: ubuntu-latest
permissions:
# Give the default GITHUB_TOKEN write permission to commit and push the
# added or changed files to the repository.
contents: write
steps:
@ -29,6 +27,7 @@ jobs:
- uses: actions/setup-go@v4
with:
go-version: "^1.17.0"
- run: go version
- name: Setup Hugo
@ -41,9 +40,11 @@ jobs:
run: hugo --minify --gc
- name: Deploy 🚀
uses: JamesIves/github-pages-deploy-action@v4
uses: easingthemes/ssh-deploy@v2
with:
branch: gh-pages
folder: public
clean: true
single-commit: true
server: ${{ secrets.SERVER_DOMAIN }}
username: ${{ secrets.SERVER_USERNAME }}
key: ${{ secrets.SSH_PRIVATE_KEY }}
local: ./public
remote: /var/www/html/