azure-pipelines

Concurrently JS application pipeline install and build hangs (Express js for server, Create-React-App for Client)

柔情痞子 提交于 2021-02-02 09:46:47
问题 Problem : I have a project with a server (Express Server that handles file uploading and deleting) and client (Front End Create-React-App). The project structure looks like follows: Root Folder With Server Client Folder Each folder has it's own package.json. Server Package.json. Client package.json I'm trying to build and deploy onto azure however the pipeline hangs on "npm install and build". It seems like the build succeeds but this phase just hangs. Here is my server.js (the routes are not

Using Lerna.js and Azure Devops Pipeline

大兔子大兔子 提交于 2021-01-29 21:37:00
问题 I'm studying about azuredevops pipelines to a new project. I'm totally new about devops. In this project, I want to use lerna.js to manage my monorepo and my packages. Considering that I have those three projects inside my monorepo: Package 1 (1.0.1) Package 2 (1.0.0) Package 3 (1.0.3) And I want to create a new TAG, which will increase the Package 3 to (1.0.4). How can I trigger an Azure Pipeline just to Package 3? There is any guide? I watched one talk about monorepos with lerna.js and I'm

How to provide docker image tag dynamically to docker-compose.yml in Azure Release Pipeline Task?

冷暖自知 提交于 2021-01-29 19:30:11
问题 I have docker-compose.yml file present in the repository. I have added the image attribute in one of the services to pull the docker images. I have not hard coded the docker image and docker tag and planning to pass these arguments at the runtime to docker-compose.yml file. How to pass the runtime arguments like IMAGE_TAG=82 , IMAGE_NAME=app1 to the docker-compose.yml file? 回答1: You can use variables in the docker-compose file for the image & tag: version: '3' services: redis-server: image: $

How to troubleshoot MissingEndParenthesisInExpression in Azure Yaml Pipelines powershell task arguments

拟墨画扇 提交于 2021-01-29 16:50:35
问题 yaml PowerShell task looks something like this: - task: PowerShell@2 displayName: 'test' inputs: targetType: filePath filePath: '$(Agent.BuildDirectory)\$(artifactName)\testpath\testscript.ps1' arguments: '-parameterFilePath $(Agent.BuildDirectory)\$(artifactName)\mainfolder\params.json -appSecurePassword (convertTo-SecureString $(appPassword) -AsPlainText -Force) -vmSecurePassword (convertTo-SecureString $(vmPassword) -AsPlainText -Force)' However, I get this error: 2020-06-09T12:54:59

Azure Devops multi-stage pipeline environment name not set properly

此生再无相见时 提交于 2021-01-29 16:24:51
问题 I'm building a multi-stage pipeline, and I'm using a lot of templates as the deploy jobs, tasks, and stages for each environment has a lot of shared logic. So on the stage I'm setting a environmentName variable, then using that in each of the jobs: - stage: StageReleaseProd displayName: Stage Release (Prod) variables: environmentName: 'prod' jobs: - deployment: DeployWebApp displayName: Deploy Wep App pool: vmImage: $(vmImage) environment: $(environmentName) strategy: runOnce: deploy: steps:

Can I programmatically set an overridable default value for a variable in an Azure DevOps Release Pipeline?

落爺英雄遲暮 提交于 2021-01-29 16:06:05
问题 I have a variable called some_var in an Azure DevOps release pipeline. I'd like to set the default at release time. But I want to set it programmatically based on the contents of a file in the artifact drop folder. But I still want the user to be able to overwrite the dynamically set value at the time they're creating the release. So the end-user behavior would be that they (1) navigate to the Release and (2) click "Create New". The dialog comes up with the some_var variable already set to a

Adding additional files to Azure Build Pipeline

元气小坏坏 提交于 2021-01-29 15:05:02
问题 I have an Azure DevOps Pipeline which pulls from a repository and builds a Visual Studio web project. This is then published to an App Service. I have several sensitive configuration files which are not included in the repository (or the VS project) and are stored as 'Secure Files' within the Azure DevOps system. I need to include these files in the 'Config/Secure' folder for the package that gets published (within the zip file). I can download them, but no matter what I try, I cannot get

Azure pipeline build Stage verification

|▌冷眼眸甩不掉的悲伤 提交于 2021-01-29 14:52:59
问题 As a centralized azure devops team in my org , we want to ensure that code of certain technology type built using standard extended yaml template. Thanks to the "Extend" feature and recently introduced template check at environment level , we are now able to verify developers yamls if they are extending our standard yamls or not. But this check only runs after build stage. Can we somehow evaluate this before build stage? 回答1: Can we somehow evaluate this before build stage? I'm afraid, no, it

How to trigger azure pipeline in one topic branch during push for another topic branch

早过忘川 提交于 2021-01-29 09:57:49
问题 My azure devops pipileine's yaml file is not in master branch of bitbucket. Its in another branch inside master branch (master/pipeline-branch). I am trying to trigger that build when there is a push to another topic branch which is also not the master branch. (master/topic/secondary). In my yaml file I have written the trigger like this. trigger: - topic/secondary But no build is triggered when I push a file to secondary branch. 回答1: you need to cherry pick\merge commits with this file to

Get task status in next step

[亡魂溺海] 提交于 2021-01-29 08:39:36
问题 I have a task Maven@3 that is running my tests and I would like to get its status in a next task. Is there a variable to get it ? For example : - task: Maven@3 displayName: UnitTest name: UnitTest inputs: ...maven options... goals: 'test' - script: echo $(succeeded('UnitTest')) In the script steps, I would like to print the UnitTest Task status. 回答1: The workaround is to use multi job pipeline to separate UnitTest task in a separate job and other jobs dependent on it. Then you can use