Nuevo testeo de CI/CD.
This commit is contained in:
@@ -1,35 +1,26 @@
|
||||
name: Build y Deploy a Producción
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main # O la rama que uses para producción
|
||||
|
||||
branches: [main]
|
||||
jobs:
|
||||
build:
|
||||
name: Construir y Subir Imágenes Docker
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout del código
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Login al Registro de Gitea
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ${{ secrets.REGISTRY_URL }}
|
||||
registry: gitea:5000
|
||||
username: ${{ gitea.actor }}
|
||||
password: ${{ secrets.ACTIONS_PAT }}
|
||||
|
||||
- name: Construir y Subir API Backend
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
context: .
|
||||
file: ./Backend/GestionIntegral.Api/Dockerfile
|
||||
push: true
|
||||
tags: |
|
||||
${{ secrets.REGISTRY_URL }}/${{ gitea.repository }}/api:latest
|
||||
${{ secrets.REGISTRY_URL }}/${{ gitea.repository }}/api:${{ gitea.sha_short }}
|
||||
tags: gitea:5000/${{ gitea.repository }}/api:latest
|
||||
|
||||
- name: Construir y Subir Frontend
|
||||
uses: docker/build-push-action@v5
|
||||
@@ -38,9 +29,7 @@ jobs:
|
||||
context: .
|
||||
file: ./Frontend/Dockerfile
|
||||
push: true
|
||||
tags: |
|
||||
${{ secrets.REGISTRY_URL }}/${{ gitea.repository }}/frontend:latest
|
||||
${{ secrets.REGISTRY_URL }}/${{ gitea.repository }}/frontend:${{ gitea.sha_short }}
|
||||
tags: gitea:5000/${{ gitea.repository }}/api:latest
|
||||
|
||||
deploy:
|
||||
name: Desplegar a Producción
|
||||
|
||||
Reference in New Issue
Block a user