diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index 9de1195..144d26b 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -13,22 +13,26 @@ jobs: - name: Checkout uses: actions/checkout@v4 - - name: Use Bun + - name: Setup Bun uses: oven-sh/setup-bun@v2 with: - node-version: '20' + bun-version: latest - name: Install dependencies run: bun install - name: Build + env: + VITE_SUPABASE_URL: ${{ vars.VITE_SUPABASE_URL }} + VITE_SUPABASE_ANON_KEY: ${{ vars.VITE_SUPABASE_ANON_KEY }} + VITE_BACK_ORIGIN: ${{ vars.VITE_BACK_ORIGIN }} run: bun run build - - name: Install Azure SWA CLI - run: bun install -g @azure/static-web-apps-cli - + # No hace falta instalar el CLI globalmente, usamos bunx - name: Deploy to Azure Static Web Apps + env: + AZURE_SWA_DEPLOYMENT_TOKEN: ${{ secrets.AZURE_SWA_DEPLOYMENT_TOKEN }} run: | - swa deploy ./dist \ + bunx @azure/static-web-apps-cli deploy ./dist \ --env production \ - --deployment-token "${{ secrets.AZURE_SWA_DEPLOYMENT_TOKEN }}" + --deployment-token "$AZURE_SWA_DEPLOYMENT_TOKEN"