Search…
⌃K
Links

Building Docker images

You can build Docker images for your Helm Charts and define any number of Docker builds for your application. Dockerfiles must be located in the application's source control repository, however, and you cannot specify Docker builds from remote source control repositories.
Here's an example of Docker builds for custom Nginx and backend containers:
builds:
- name: nginx
dockerfile: Dockerfile
context: nginx
args:
- MAX_UPLOAD_SIZE=60
- name: backend
dockerfile: Dockerfile-backend
context: app

Build environment variables

Each container built by ReleaseHub will generate environment variables that can be used in your Helm Charts. By default, ReleaseHub adds environment variables for the Docker registry and path to the image built.
- key: RELEASE_REGISTRY_ENDPOINT
value: 123456789000.dkr.ecr.us-east-1.amazonaws.com
secret: false
- key: RELEASE_REGISTRY_PATH
value: 123456789000.dkr.ecr.us-east-1.amazonaws.com/acme-org/acme-app
secret: false
Two environment variables are emitted per build. The Ngnix build in our example above will generate the variables NGINX_REGISTRY_IMAGE_URL and NGINX_REGISTRY_IMAGE_SHA.
Here's an example of generated build environment variables:
- key: NGINX_REGISTRY_IMAGE_URL
value: 123456789000.dkr.ecr.us-east-1.amazonaws.com/acme-org/acme-app/[email protected]:f1e8b983e8f842170caed5ce76fa92171acfc0f8296283c85155771374adec9c
secret: false
- key: NGINX_REGISTRY_IMAGE_SHA
value: f1e8b983e8f842170caed5ce76fa92171acfc0f8296283c85155771374adec9c
- key: BACKEND_REGISTRY_IMAGE_URL
value: 123456789000.dkr.ecr.us-east-1.amazonaws.com/acme-org/acme-app/[email protected]:4852bafb7f7cf76375d0e090f737926210de462ef35c9f9616f8a2e17ebb0dda
secret: false
- key: BACKEND_REGISTRY_IMAGE_SHA
value: 4852bafb7f7cf76375d0e090f737926210de462ef35c9f9616f8a2e17ebb0dda
secret: false