简体   繁体   中英

How do I create a TFS 2017 CI/CD pipeline for an angular 7 app

Is it possible to create a CI/CD pipeline for an Angular 7 app using an on premise install of TFS 2017?

I have done this on the cloud based VSTS and DevOps using the npm templates but these build tasks don't seem to be available on TFS 2017.

I was thinking of creating a power shell script and running it as a build task but I have read issues with this method such as having to install the Angular CLI each time you build and problems with install locations on the build server.

I cannot upgrade the build server to use DevOps but I can install nodejs and anything else which may be required.

What I want to do is to build the angular code on checking, run the unit tests and deploy to another server if all is successful.

You could take a look at this detail tutorial here-- Angular 7 with Azure DevOps Build Pipeline

Even though it's using YAML, it should be the same result if you are using visual UI in TFS/Azure DevOps Server.

It's just using npm command to run the build, kind of npm run pro-build-dev .

If there is no such npm task in your TFS2017 server, you could try to download it from opensource GitHub Reop-- azure-pipelines-tasks . Or build your own task to involve the npm command line by referring the source code.

For build agent environment, you just need to make sure it's the same as your local environment. If you are fine to build your angular 7 app in your local develop machine. You should also be able to build it without any environment issue on your build agent.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM