Skip to content

Commit 0f98877

Browse files
authored
Merge pull request #9 from dlepow/multistep
Added yaml files for multistep tutorial
2 parents cf9ffdf + a6af2c2 commit 0f98877

File tree

3 files changed

+40
-5
lines changed

3 files changed

+40
-5
lines changed

README.md

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,30 @@
11
# ACR Build Hello World
22

3-
This Node.js application is for use in demonstrating Azure Container Registry Build (ACR Build), a suite of features within [Azure Container Registry](https://azure.microsoft.com/services/container-registry/) for performing Docker container builds on [Azure](https://azure.com).
3+
This Node.js application is for use in demonstrating scenarios for Azure Container Registry Tasks. [ACR Tasks](https://docs.microsoft.com/azure/container-registry/container-registry-tasks-overview) is a suite of features within [Azure Container Registry](https://azure.microsoft.com/services/container-registry/) for performing Docker container builds on [Azure](https://azure.com), as well as automated OS and framework patching for Docker containers.
44

55
## Features
66

7-
This project includes three Dockerfiles:
7+
This project includes the following Dockerfiles:
88

99
* *Dockerfile* - Non-parameterized Dockerfile for building the application. References a base image in Docker Hub.
1010
* *Dockerfile-app* - Parameterized, accepts the `REGISTRY_NAME` argument to specify the FQDN of the container registry from which the base image is pulled.
1111
* *Dockerfile-base* - Defines a base image for the application defined in *Dockerfile-app*.
1212

13+
This project also includes the following YAML files:
14+
15+
* *taskmulti.yaml* - Specifies a multistep task to build, run, and push a container image specified by *Dockerfile*.
16+
* *taskmulti-multiregistry.yaml* - Specifies a multistep task to build, run, and push container images specified by *Dockerfile* to multiple registries.
17+
1318
## Getting Started
1419

1520
### Companion articles
1621

1722
This project is intended for use with the following articles on [docs.microsoft.com][docs]:
1823

19-
* [Build container images in the cloud with Azure Container Registry Build][build-quick]
20-
* [Automate container image builds with Azure Container Registry Build][build-task]
21-
* [Automate image builds on base image update with Azure Container Registry Build][build-base]
24+
* [Build container images in the cloud with Azure Container Registry Tasks][build-quick]
25+
* [Automate container image builds in the cloud when you commit source code][build-task]
26+
* [Run a multi-step container workflow in the cloud when you commit source code][multi-step]
27+
* [Automate container image builds when a base image is updated in an Azure container registry][build-base]
2228

2329
### Quickstart
2430

@@ -40,4 +46,5 @@ Although intended for use with the companion articles, you can perform the follo
4046
[build-quick]: https://docs.microsoft.com/azure/container-registry/container-registry-tutorial-quick-build
4147
[build-task]: https://docs.microsoft.com/azure/container-registry/container-registry-tutorial-build-task
4248
[build-base]: https://docs.microsoft.com/azure/container-registry/container-registry-tutorial-base-image-update
49+
[multi-step]: https://docs.microsoft.com/azure/container-registry/container-registry-tutorial-multistep-task
4350
[docs]: http://docs.microsoft.com

taskmulti-multiregistry.yaml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
version: v1.0.0
2+
steps:
3+
# Build target images
4+
- build: -t {{.Run.Registry}}/hello-world:{{.Run.ID}} -f Dockerfile .
5+
- build: -t {{.Values.regDate}}/hello-world:{{.Run.Date}} -f Dockerfile .
6+
# Run image
7+
- cmd: -t {{.Run.Registry}}/hello-world:{{.Run.ID}}
8+
id: test
9+
detach: true
10+
ports: ["8080:80"]
11+
- cmd: docker stop test
12+
# Push images
13+
- push:
14+
- {{.Run.Registry}}/hello-world:{{.Run.ID}}
15+
- {{.Values.regDate}}/hello-world:{{.Run.Date}}

taskmulti.yaml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
version: v1.0.0
2+
steps:
3+
# Build target image
4+
- build: -t {{.Run.Registry}}/hello-world:{{.Run.ID}} -f Dockerfile .
5+
# Run image
6+
- cmd: -t {{.Run.Registry}}/hello-world:{{.Run.ID}}
7+
id: test
8+
detach: true
9+
ports: ["8080:80"]
10+
- cmd: docker stop test
11+
# Push image
12+
- push:
13+
- {{.Run.Registry}}/hello-world:{{.Run.ID}}

0 commit comments

Comments
 (0)