Last active
February 15, 2021 08:56
-
-
Save LordBastor/985db78c8544867e6335b3916f35b1fc to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pool: | |
vmImage: ubuntu-latest | |
variables: | |
- name: ACR | |
value: ACR_URL | |
- name: AZURE_STORAGE_CONNECTION_STRING | |
value: AZURE_STORAGE_CONNECTION_STRING | |
- name: ACR_USER | |
value: ACR_USER | |
- name: ACR_PASSWORD | |
value: ACR_PASSWORD | |
- name: PROJECT | |
value: prefect | |
stages: | |
- stage: deployment | |
jobs: | |
- job: register | |
pool: private-agent | |
variables: | |
IMAGE_URL: "$(ACR)/$(PROJECT):latest" | |
steps: | |
#register the flows that changed | |
- template: templates/register-flows.yml | |
parameters: | |
project: $(PROJECT) | |
- job: build | |
dependsOn: register | |
steps: | |
#build a docker image and push to ACR | |
- template: templates/docker-build.yml | |
parameters: | |
image: "$(ACR)/$(PROJECT)" | |
tag: latest | |
- template: templates/docker-login.yml | |
parameters: | |
repo: $(ACR) | |
user: $(ACR_USER) | |
password: $(ACR_PASSWORD) | |
- template: templates/docker-push.yml | |
parameters: | |
image: "$(ACR)/$(PROJECT)" | |
tag: latest | |
trigger: | |
branches: | |
include: | |
- '*' | |
paths: | |
include: | |
- 'flows/' | |
- 'tasks/' | |
- 'config/' | |
exclude: | |
- '*' | |
- '*__init__.py*' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment