Skip to content

Update README.MD

Update README.MD #3

Workflow file for this run

name: Deploy to VPS
on:
workflow_dispatch: # ← Esto permite lanzarlo manualmente desde la interfaz
push:
branches: [main]
env:
DEPLOY_DIR: ${{ github.actor }} # Usará el nombre de usuario de GitHub automáticamente
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Crear carpeta remota (si no existe)
uses: appleboy/ssh-action@v0.1.8
with:
host: ${{ secrets.VPS_HOST }}
username: ${{ secrets.VPS_USER }}
key: ${{ secrets.DEPLOY_KEY }}
port: 2222
script: |
mkdir -p /var/www/html/evento/tecuruapan/${{ env.DEPLOY_DIR }}
- name: Subir sitio al VPS
uses: appleboy/scp-action@v0.1.3
with:
host: ${{ secrets.VPS_HOST }}
username: ${{ secrets.VPS_USER }}
key: ${{ secrets.DEPLOY_KEY }}
port: 2222
source: "./*"
target: "/var/www/html/evento/tecuruapan/${{ env.DEPLOY_DIR }}"