From 58ba68e0e14b6ec87d6b6d34b926a8bf5858bd49 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antoni=20Nu=C3=B1ez=20Romeu?= Date: Thu, 21 May 2026 15:55:51 +0200 Subject: [PATCH] cicd fix --- .gitea/workflows/docker.yaml | 86 ++++++++++++++++++------------------ 1 file changed, 43 insertions(+), 43 deletions(-) diff --git a/.gitea/workflows/docker.yaml b/.gitea/workflows/docker.yaml index 8d1a308..3d04989 100644 --- a/.gitea/workflows/docker.yaml +++ b/.gitea/workflows/docker.yaml @@ -4,63 +4,63 @@ run-name: ${{ gitea.actor }} - ${{ gitea.ref }} on: push: branches: - - main + - main jobs: test-backend: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - name: Install dependencies - run: cd backend && npm ci - - name: Run tests - run: cd backend && npm test + - uses: actions/checkout@v3 + - name: Install dependencies + run: cd backend && npm ci + - name: Run tests + run: cd backend && npm test test-frontend: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - name: Install dependencies - run: cd frontend && npm ci - - name: Run tests - run: cd frontend && npm test + - uses: actions/checkout@v3 + - name: Install dependencies + run: cd frontend && npm ci + - name: Run tests + run: cd frontend && npm test build-backend: - needs: [test-backend, test-frontend] + needs: [ test-backend, test-frontend ] runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - name: Log in to Gitea registry - uses: docker/login-action@v3 - with: - registry: git.hacecalor.net - username: ${{ gitea.actor }} - password: ${{ gitea.token }} - - name: Build and push backend image - uses: docker/build-push-action@v5 - with: - context: ./backend - push: true - tags: | - git.hacecalor.net/ichitux/farmafinder-backend:latest - git.hacecalor.net/ichitux/farmafinder-backend:${{ gitea.sha }} + - uses: actions/checkout@v3 + - name: Log in to Gitea registry + uses: docker/login-action@v3 + with: + registry: git.hacecalor.net + username: ${{ secrets.DOCKER_USERNAME }} + password: ${{ secrets.DOCKER_PASSWORD }} + - name: Build and push backend image + uses: docker/build-push-action@v5 + with: + context: ./backend + push: true + tags: | + git.hacecalor.net/ichitux/farmafinder-backend:latest + git.hacecalor.net/ichitux/farmafinder-backend:${{ gitea.sha }} build-frontend: - needs: [test-backend, test-frontend] + needs: [ test-backend, test-frontend ] runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - name: Log in to Gitea registry - uses: docker/login-action@v3 - with: - registry: git.hacecalor.net - username: ${{ gitea.actor }} - password: ${{ gitea.token }} - - name: Build and push frontend image - uses: docker/build-push-action@v5 - with: - context: ./frontend - push: true - tags: | - git.hacecalor.net/ichitux/farmafinder-frontend:latest - git.hacecalor.net/ichitux/farmafinder-frontend:${{ gitea.sha }} + - uses: actions/checkout@v3 + - name: Log in to Gitea registry + uses: docker/login-action@v3 + with: + registry: git.hacecalor.net + username: ${{ secrets.DOCKER_USERNAME }} + password: ${{ secrets.DOCKER_PASSWORD }} + - name: Build and push frontend image + uses: docker/build-push-action@v5 + with: + context: ./frontend + push: true + tags: | + git.hacecalor.net/ichitux/farmafinder-frontend:latest + git.hacecalor.net/ichitux/farmafinder-frontend:${{ gitea.sha }}