Configurando para lanzar con tag
Some checks failed
CD for Blog / build (push) Has been cancelled

This commit is contained in:
2024-03-09 01:10:06 -03:00
parent 043c0c028e
commit 41d32d9415

View File

@@ -2,7 +2,8 @@ name: CD for Blog
on:
push:
branches: [main]
tags:
- '*'
jobs:
build:
@@ -21,18 +22,4 @@ jobs:
context: .
file: ./Dockerfile
push: true
tags: git.skrd.fun/skrd/danielcortes.xyz:latest
deploy:
needs: build
runs-on: ubuntu-latest
steps:
- name: Deploy
run: |
echo "${{ secrets.SERVER_PRIVATE_KEY }}" > private_key && chmod 600 private_key
ssh -o StrictHostKeyChecking=no -i private_key ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }} -p ${{ secrets.SSH_PORT || 22 }} '
docker compose pull
docker compose up -d
'
tags: git.skrd.fun/skrd/danielcortes.xyz:${{github.ref_name}}