# # Run functional test on bot deployed to a Docker Linux environment in Azure. # pool: vmImage: 'Ubuntu-16.04' trigger: # ci trigger branches: include: - master pr: none # no pr trigger variables: # Container registry service connection established during pipeline creation dockerRegistryServiceConnection: 'NightlyE2E-Acr' azureRmServiceConnection: 'NightlyE2E-RM' dockerFilePath: 'libraries/functional-tests/functionaltestbot/Dockerfile' buildIdTag: $(Build.BuildNumber) webAppName: 'e2epython' containerRegistry: 'nightlye2etest.azurecr.io' imageRepository: 'functionaltestpy' # LinuxTestBotAppId: get this from azure # LinuxTestBotAppSecret: get this from Azure jobs: - job: Build displayName: Build and push bot image continueOnError: false steps: - task: Docker@2 displayName: Build and push bot image inputs: command: buildAndPush repository: $(imageRepository) dockerfile: $(dockerFilePath) containerRegistry: $(dockerRegistryServiceConnection) tags: $(buildIdTag) - job: Deploy displayName: Provision bot container dependsOn: - Build steps: - task: AzureRMWebAppDeployment@4 displayName: Python Functional E2E test. inputs: ConnectionType: AzureRM ConnectedServiceName: $(azureRmServiceConnection) appType: webAppContainer WebAppName: $(webAppName) DockerNamespace: $(containerRegistry) DockerRepository: $(imageRepository) DockerImageTag: $(buildIdTag) AppSettings: '-MicrosoftAppId $(LinuxTestBotAppId) -MicrosoftAppPassword $(LinuxTestBotAppSecret) -FLASK_APP /functionaltestbot/app.py -FLASK_DEBUG 1' #StartupCommand: 'flask run --host=0.0.0.0 --port=3978'