Advertisement
Guest User

Untitled

a guest
Oct 10th, 2019
91
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.44 KB | None | 0 0
  1. trigger:
  2. branches:
  3. include:
  4. - master
  5. paths:
  6. include:
  7. - Case/FrontEnd/*
  8.  
  9. pool:
  10. vmImage: 'ubuntu-latest'
  11.  
  12. variables:
  13. buildConfiguration: 'Release'
  14. projectPath: 'Case/FrontEnd/FrontEnd/**/*.csproj'
  15.  
  16. steps:
  17. - task: UseDotNet@2
  18. inputs:
  19. packageType: 'sdk'
  20. version: '3.0.100'
  21.  
  22. - task: DotNetCoreCLI@2
  23. inputs:
  24. command: 'restore'
  25. projects: '$(projectPath)'
  26.  
  27. - task: DotNetCoreCLI@2
  28. displayName: 'dotnet build'
  29. inputs:
  30. command: build
  31. projects: '$(projectPath)'
  32. arguments: '--configuration $(BuildConfiguration) --no-restore'
  33.  
  34. - task: DotNetCoreCLI@2
  35. displayName: 'dotnet test'
  36. inputs:
  37. command: test
  38. projects: 'Case/FrontEnd/**/*Test/*.csproj'
  39. arguments: '--configuration $(BuildConfiguration) --no-restore'
  40.  
  41. - task: DotNetCoreCLI@2
  42. displayName: 'dotnet publish'
  43. inputs:
  44. command: publish
  45. publishWebProjects: false
  46. projects: Case/FrontEnd/FrontEnd/FrontEnd.csproj
  47. arguments: '--configuration $(BuildConfiguration) -f "netcoreapp3.0" -r "linux-x64" --output "Case/FrontEnd/FrontEnd/bin/Release/netcoreapp3.0/publish"'
  48. zipAfterPublish: false
  49. modifyOutputPath: false
  50.  
  51. - task: Docker@2
  52. inputs:
  53. containerRegistry: 'Minor2019Registry'
  54. repository: 'yb-case-frontend-i'
  55. tags: 'latest'
  56. command: 'buildAndPush'
  57. buildContext: 'Case/FrontEnd/FrontEnd/'
  58. Dockerfile: 'Case/FrontEnd/FrontEnd/Dockerfile'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement