Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

4 лет назад
4 лет назад
4 лет назад
5 лет назад
4 лет назад
4 лет назад
4 лет назад
4 лет назад
4 лет назад
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  1. # Refer: https://aka.ms/yaml
  2. variables:
  3. shouldDeploy: >-
  4. ${{ eq(variables['Build.SourceBranch'], 'refs/heads/master') }}
  5. deployDest: ${{ format('~/web/{0}/', variables['Build.SourceBranchName']) }}
  6. stages:
  7. - stage: build_test
  8. displayName: Build and Test
  9. jobs:
  10. - job: win_vs2019
  11. displayName: Windows - VS 2019
  12. pool:
  13. vmImage: windows-2019
  14. steps:
  15. - pwsh: tools\get-win-openssl.ps1
  16. displayName: Get OpenSSL for Windows
  17. - script: python -m pip install poetry && poetry install --no-dev
  18. displayName: Install Python deps
  19. - script: |
  20. echo Loading VS environment
  21. call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\Tools\vsdevcmd" -arch=x64 || exit 1
  22. echo Executing Build and Tests
  23. reg add HKLM\SYSTEM\CurrentControlSet\Control\FileSystem /v LongPathsEnabled /t REG_DWORD /d 1 /f || exit 1
  24. poetry run dds-ci || exit 1
  25. move _build\dds.exe _build\dds-win-x64.exe || exit 1
  26. displayName: Build and Test
  27. - task: PublishTestResults@2
  28. displayName: Publish Tests
  29. condition: succeededOrFailed()
  30. inputs:
  31. testResultsFiles: '**/pytest-junit.xml'
  32. failTaskOnFailedTests: true
  33. testRunTitle: Windows Tests
  34. - publish: _build\dds-win-x64.exe
  35. displayName: Publish
  36. artifact: dds-win-x64
  37. - job: linux_gcc9
  38. displayName: Linux - GCC 9
  39. pool:
  40. vmImage: ubuntu-18.04
  41. steps:
  42. - script: make alpine-static-ci
  43. displayName: Build and Test
  44. - task: PublishTestResults@2
  45. displayName: Publish Tests
  46. condition: succeededOrFailed()
  47. inputs:
  48. testResultsFiles: '**/pytest-junit.xml'
  49. failTaskOnFailedTests: true
  50. testRunTitle: Linux Tests
  51. - publish: _build/dds-linux-x64
  52. displayName: Publish
  53. artifact: dds-linux-x64
  54. - job: macos_gcc9
  55. displayName: macOS - GCC 9
  56. pool:
  57. vmImage: macOS-10.15
  58. steps:
  59. - script: brew install gcc@9 ccache
  60. displayName: Get GCC 9
  61. - script: brew install openssl@1.1
  62. displayName: Install OpenSSL
  63. - script: python3 -m pip install poetry
  64. displayName: Get Python Dependencies
  65. - script: make macos-ci
  66. displayName: Build and Test
  67. - task: PublishTestResults@2
  68. displayName: Publish Tests
  69. condition: succeededOrFailed()
  70. inputs:
  71. testResultsFiles: '**/pytest-junit.xml'
  72. failTaskOnFailedTests: true
  73. testRunTitle: macOS Tests
  74. - publish: _build/dds-macos-x64
  75. displayName: Publish
  76. artifact: dds-macos-x64
  77. - stage: deploy_build
  78. displayName: Deploy
  79. condition: and(succeeded(), eq(variables.shouldDeploy, 'true'))
  80. jobs:
  81. - job: deploy
  82. displayName: Deploy (${{variables['Build.SourceBranch']}})
  83. steps:
  84. - checkout: none
  85. - task: DownloadPipelineArtifact@2
  86. displayName: Download builds
  87. inputs:
  88. targetPath: art-dirs/
  89. - bash: |
  90. set -eu
  91. mkdir -p art/
  92. mv -- $(find art-dirs/ -type f) art/
  93. displayName: Rearrange
  94. - task: CopyFilesOverSSH@0
  95. displayName: Post builds
  96. inputs:
  97. sshEndpoint: dds.pizza
  98. sourceFolder: art/
  99. targetFolder: ${{ variables.deployDest }}
  100. failOnEmptySource: true
  101. overwrite: true