forked from mmumshad/example-voting-app
-
Notifications
You must be signed in to change notification settings - Fork 0
/
azure-pipelines.yml
32 lines (25 loc) · 1004 Bytes
/
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
# Docker image
# Build a Docker image to deploy, run, or push to a container registry.
# Add steps that use Docker Compose, tag images, push to a registry, run an image, and more:
# https://docs.microsoft.com/azure/devops/pipelines/languages/docker
trigger:
- master
pool:
vmImage: 'Ubuntu-16.04'
variables:
acrId: acrtestmumshad
acrPswd: LRoyTf/oFUZMdHEOXb7bNidtC=lJUlUN
steps:
- script: |
docker build -t $(acrId).azurecr.io/result:$(build.buildId) ./result
displayName: 'Build result'
- script: docker build -t $(acrId).azurecr.io/vote:$(build.buildId) ./vote
displayName: 'Build vote'
- script: docker build -t $(acrId).azurecr.io/worker:$(build.buildId) ./worker
displayName: 'Build worker'
- script: |
docker login -u $(acrId) -p $(acrPswd) $(acrId).azurecr.io
docker push $(acrId).azurecr.io/result:$(build.buildId)
docker push $(acrId).azurecr.io/vote:$(build.buildId)
docker push $(acrId).azurecr.io/worker:$(build.buildId)
displayName: 'Push all images'