forked from microsoft/presidio
-
Notifications
You must be signed in to change notification settings - Fork 0
/
azure-pipelines.yml
35 lines (35 loc) · 1.09 KB
/
azure-pipelines.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
resources:
- repo: self
queue:
name: Hosted Ubuntu 1604
timeoutInMinutes: 60
variables:
GOBIN: '$(GOPATH)/bin'
GOPATH: '$(system.defaultWorkingDirectory)/gopath'
modulePath: '$(GOPATH)/src/github.com/$(build.repository.name)'
GOROOT: '/usr/local/go1.11'
steps:
- task: Docker@1
displayName: 'ACR Login'
inputs:
containerregistrytype: 'Container Registry'
dockerRegistryEndpoint: presidio
command: login
- bash: |
mkdir -p '$(GOBIN)'
mkdir -p '$(GOPATH)/pkg'
mkdir -p '$(modulePath)'
shopt -s extglob
mv !(gopath) '$(modulePath)'
echo '##vso[task.prependpath]$(GOBIN)'
echo '##vso[task.prependpath]$(GOROOT)/bin'
displayName: 'Setup Go Env'
- bash: |
curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
dep ensure
make DOCKER_REGISTRY=$(DOCKER_REGISTRY) PRESIDIO_LABEL=$(Build.BuildID) test-functional
workingDirectory: '$(modulePath)'
displayName: 'Build & Test '
- bash: 'make DOCKER_REGISTRY=$(DOCKER_REGISTRY) PRESIDIO_LABEL=$(Build.BuildID) docker-push'
workingDirectory: '$(modulePath)'
displayName: 'Push Docker Images'