Created
October 5, 2022 15:14
-
-
Save mnakka9/5f3f7b1e779b7c9b80b55751ab03bbdf to your computer and use it in GitHub Desktop.
Pipeline for Ng Universal in IIS
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| trigger: | |
| - main | |
| pool: | |
| vmImage: ubuntu-latest | |
| steps: | |
| - task: NodeTool@0 | |
| inputs: | |
| versionSpec: '14.x' | |
| displayName: 'Install Node.js' | |
| - script: | | |
| cd nguniversal | |
| npm install -g @angular/cli | |
| npm install | |
| npm run build:ssr | |
| displayName: 'npm install and build' | |
| # Copying all the files from sever folder to root | |
| # (make sure you use appropriate folder names from your project) | |
| - task: CopyFiles@2 | |
| inputs: | |
| SourceFolder: 'nguniversal/dist/nguniversal/server' | |
| Contents: '**' | |
| TargetFolder: 'nguniversal/dist/nguniversal' | |
| # Copying web.config from browser folder to root (this is the file we added) | |
| - task: CopyFiles@2 | |
| inputs: | |
| SourceFolder: 'nguniversal/dist/nguniversal/browser' | |
| Contents: 'web.config' | |
| TargetFolder: 'nguniversal/dist/nguniversal' | |
| - task: PublishBuildArtifacts@1 | |
| inputs: | |
| PathtoPublish: 'nguniversal/dist/' | |
| ArtifactName: 'dist' | |
| publishLocation: 'Container' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment