浏览代码

Cleanup and path fixes

default_compile_flags
vector-of-bool 4 年前
父节点
当前提交
e4ea3ac336
共有 2 个文件被更改,包括 8 次插入51 次删除
  1. +0
    -27
      azure-deploy.yml
  2. +8
    -24
      azure-pipelines.yml

+ 0
- 27
azure-deploy.yml 查看文件

@@ -1,27 +0,0 @@
parameters:
- name: branch
type: string
displayName: Branch
- name: targetPath
type: string
displayName: Target Path

jobs:
- ${{ if eq(variables.build.SourceBranchName, parameters.branch) }}:
- job: deploy_${{ parameters.branch }}
displayName: Deploy for ${{parameters.branch}}
condition: succeeded()
steps:
- task: DownloadPipelineArtifact@2
displayName: Download builds
inputs:
targetPath: art/
- task: CopyFilesOverSSH@0
displayName: Post builds
inputs:
sshEndpoint: dds.pizza
sourceFolder: art/
targetFolder: ${{ parameters.targetPath }}
failOnEmptySource: true
overwrite: true


+ 8
- 24
azure-pipelines.yml 查看文件

@@ -1,11 +1,12 @@
# Refer: https://aka.ms/yaml

variables:
shouldDeploy: >
shouldDeploy: >-
${{ or(
eq(variables.Build.SourceBranch, 'refs/heads/develop'),
eq(variables.Build.SourceBranch, 'refs/heads/master')
eq(variables['Build.SourceBranch'], 'refs/heads/develop'),
eq(variables['Build.SourceBranch'], 'refs/heads/master')
) }}
deployDest: ${{ format('~/{0}/', variables['Build.SourceBranchName']) }}

stages:
- stage: build_test
@@ -64,12 +65,12 @@ stages:

- stage: deploy_build
displayName: Deploy
condition: eq(variables.shouldDeploy, true)
condition: and(succeeded(), eq(variables.shouldDeploy, 'true'))
jobs:
- job: deploy
displayName: Deploy for ${{variables.Build.SourceBranchName}}
condition: succeeded()
displayName: Deploy (${{variables['Build.SourceBranch']}})
steps:
- checkout: none
- task: DownloadPipelineArtifact@2
displayName: Download builds
inputs:
@@ -79,23 +80,6 @@ stages:
inputs:
sshEndpoint: dds.pizza
sourceFolder: art/
targetFolder: ~/${{variables.Build.SourceBranchName}}/
targetFolder: ${{ variables.deployDest }}
failOnEmptySource: true
overwrite: true
# - job: deploy
# displayName: Deploy Canary
# # Only deploy the "canary" build when we are on the 'develop' branch
# condition: and(succeeded(), eq(variables.Build.SourceBranchName, 'develop'))
# steps:
# - task: DownloadPipelineArtifact@2
# displayName: Download builds
# inputs:
# targetPath: art/
# - task: CopyFilesOverSSH@0
# displayName: Post builds
# inputs:
# sshEndpoint: dds.pizza
# sourceFolder: art/
# targetFolder: ~/canary/
# failOnEmptySource: true
# overwrite: true

正在加载...
取消
保存