Add deployment job
Some checks failed
/ build (push) Successful in 17s
/ deploy (push) Failing after 16s

This commit is contained in:
Correl Roush 2024-09-06 01:16:26 -04:00
parent 33270c3772
commit a8fd057230

View file

@ -25,3 +25,32 @@ jobs:
with: with:
name: html.tar.gz name: html.tar.gz
path: /tmp/html.tar.gz path: /tmp/html.tar.gz
deploy:
needs: build
runs-on: docker
steps:
- name: Download tarball
uses: actions/download-artifact@v3
with:
name: html.tar.gz
path: /tmp/html.tar.gz
- name: Extract tarball
run: |
tar -C /tmp zxvf /tmp/html.tar.gz
- name: Install Rsync
run: |
apt update & & apt install -y rsync
- name: Set up SSH key
run: |
mkdir -p ~/.ssh
cat <<EOF > ~/.ssh/config
Host reason
HostName reason.sailmaker.fenix.lgbt
User correlr
IdentityFile ~/.ssh/id_rsa
StrictHostKeyChecking no
EOF
echo "${{ secrets.ssh_private_key }}" > ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa
- name: Rsync HTML
run: rsync -avz --delete /tmp/public/ reason:Public/hugo/