DEV Community

Discussion on: Gitlab CI script to deploy a Azure Function

Collapse
 
oskarspakers profile image
Oskars

Thanks for the article, it helped a lot.
Here`s my sample with update dependencies dotnet 6, nodejs 16 and azure function core tools 4


deploy_prod:
  stage: deploy
  image: mcr.microsoft.com/dotnet/sdk:6.0
  script:
    - curl -sL https://aka.ms/InstallAzureCLIDeb | bash
    - apt-get install curl && curl -sL https://deb.nodesource.com/setup_16.x | bash -
    - apt-get install nodejs
    - npm install -g azure-functions-core-tools@4 --unsafe-perm true
    - az login --service-principal -u $APPLICATION_ID -p $APPLICATION_SECRET --tenant $TENANT_ID
    - func azure functionapp publish $FUNCTION_APP --nodejs