Azure / Azure/static-web-apps-cli

Github actions deploying only to production instead of preview environments

Abierto
#661 3 comentarios 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

status: investigating type: bug
Lenguaje dominante
TypeScript
Estrellas
668
Forks
155
Métricas de merge de PR
Sin PR fusionados en 30 d

Descripción

Describe the bug
I have noticed the last few github action builds have been deployed to the production website instead of the preview environment.
The workflow file hasn't changed and the branch is not the main branch.
This seems to have happened since the docker image at mcr.microsoft.com/appsvc/staticappsclient:stable was updated.
The last successful run was when github actions was using the docker image with a sha digest of:
6e8c2f7004cfd75ccbf2d1f5a402999432989eecd692d5536d47d46a07bb22ff

This issue started happening since the stable docker image was updated with a sha digest of:
870e5b73cf8d832615253d71b5834563b581a3fdf1a3defc26ccdfa264b37235

Github actions

- name: Build And Deploy
        id: builddeploy
        uses: Azure/static-web-apps-deploy@v1
        with:
          azure_static_web_apps_api_token: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN_BLUE_COAST_044CD3B03 }}
          repo_token: ${{ secrets.GITHUB_TOKEN }}
          action: "upload"                    
          app_location: "/"
          api_location: "api/api"
          output_location: "dist"
          production_branch: "main"

Screenshots
This is what used to happen:
swa-good

And now it's not going to a develop preview environment:
swa-bad

Hopefully this issue can be fixed. Happy to provide more details if needed.
Really enjoying Static Web Apps by the way. Great work!

Guía de contribución

Abrir la guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Línea de trabajo

Comienza con el workflow de GitHub Actions mostrado en el issue y compara los deployments usando los image digests 6e8c2f7004cfd75ccbf2d1f5a402999432989eecd692d5536d47d46a07bb22ff y 870e5b73cf8d832615253d71b5834563b581a3fdfc26ccdfa264b37235. Inspecciona el comportamiento de Azure Static Web Apps deploy action para ramas que no sean main y determina si los preview deployments se restauran sin afectar a producción.

Escrito por el modelo de indexación a partir del texto del issue.

Evaluación

Stack tecnológico
azure, docker, github-actions
Área
ci-cd, cloud, devops
Tipo de issue
Error
Dificultad
4/5
Tiempo estimado
3-5 días
Estado de actividad
Estancado
Claridad
Bastante claro
Aptitud para principiantes
35/100

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.