GitLab CI/CD Pipeline Stuck and Failing During Azure Login Authentication

DesignNBuy 0 Reputation points
2024-09-17T13:40:17.82+00:00

Dear Support Team,

I am experiencing an issue with my GitLab CI/CD pipeline where the pipeline gets stuck and eventually fails during the Azure login authentication phase. Here are the details:

Issue Summary:

  • Problem: The pipeline gets stuck and eventually fails when attempting to authenticate with Azure using the az login command in the CI/CD pipeline. The same login command works successfully when run manually in the terminal.
  • Error: The pipeline fails with no specific error message, but it gets stuck at the az login step before eventually failing.

Pipeline Configuration:

  • .gitlab-ci.yml Configuration: image: mcr.microsoft.com/azure-cli stages:
    • deploy
    deploy: stage: deploy script:
    - echo "Authenticating with Azure..."
    
    - az login --service-principal -u $ClientID -p $ClientPass --tenant $TenantId
    
    - echo "Deploying to Azure..."
    
    - az webapp deployment source config-zip --resource-group octopus-rg --name apioctopus --src ./octopus-backend.zip
    
    only:
    - develop
    

Thank you for your support in resolving this issue. Please let me know if additional information or logs are required.

Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
7,913 questions
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.