page_type | languages | products | description | urlFragment | ||
---|---|---|---|---|---|---|
sample |
|
|
This Node.js application is for use in demonstrating scenarios for Azure Container Registry Tasks. |
acr-build-helloworld-node |
This Node.js application is for use in demonstrating scenarios for Azure Container Registry Tasks. ACR Tasks is a suite of features within Azure Container Registry for performing Docker container builds on Azure, as well as automated OS and framework patching for Docker containers.
This project includes the following Dockerfiles:
- Dockerfile - Non-parameterized Dockerfile for building the application. References a base image in Docker Hub.
- Dockerfile-app - Parameterized, accepts the
REGISTRY_NAME
argument to specify the FQDN of the container registry from which the base image is pulled. - Dockerfile-base - Defines a base image for the application defined in Dockerfile-app.
This project also includes the following YAML files:
- taskmulti.yaml - Specifies a multistep task to build, run, and push a container image specified by Dockerfile.
- taskmulti-multiregistry.yaml - Specifies a multistep task to build, run, and push container images specified by Dockerfile to multiple registries.
This project is intended for use with the following articles on docs.microsoft.com:
- Build container images in the cloud with Azure Container Registry Tasks
- Automate container image builds in the cloud when you commit source code
- Run a multi-step container workflow in the cloud when you commit source code
- Automate container image builds when a base image is updated in an Azure container registry
Although intended for use with the companion articles, you can perform the following steps to run the sample application. These steps require a local Docker installation.
git clone https://github.com/Azure-Samples/acr-build-helloworld-node
cd acr-build-helloworld-node
docker build -t helloacrbuild:v1 .
docker run -d -p 8080:80 helloacrbuild:v1
- Navigate to http://localhost:8080 to view the running application