blog/.gitea/workflows/main-build.yaml
Emin Arslan 3297ce3d02
Some checks failed
Build & Deploy / build-or-sth (push) Failing after 32s
Added deploy step
2024-11-16 15:49:34 +03:00

27 lines
891 B
YAML

name: Build & Deploy
on:
push:
branches:
- main
jobs:
build-or-sth:
runs-on: ubuntu-latest
steps:
- run: echo "hi!"
- name: Clone repo
run: git clone --recurse-submodules https://git.emin.software/haxala1r/blog.git --depth=1 .
- name: Get hugo
run: wget https://github.com/gohugoio/hugo/releases/download/v0.131.0/hugo_extended_0.131.0_linux-amd64.tar.gz -O hugo.tar.gz
- run: tar xzvf hugo.tar.gz
- run: pwd
- run: ls -la
- name: build
run: ./hugo
- name: deploy
run: |
echo "${{ secrets.SSH_KEY }}" > /tmp/id
chmod 600 /tmp/id
scp -oUser=${{secrets.SSH_USER}} -i /tmp/id -r public/* emin.software:/home/${{ secrets.SSH_USER }}/web/web/