1
0
mirror of https://github.com/goreleaser/goreleaser.git synced 2025-02-03 13:11:48 +02:00

docs: docker: improved notes about templates

This commit is contained in:
Carlos Alexandro Becker 2018-10-12 00:08:39 -03:00
parent 71aba28e18
commit 441e5e551f
No known key found for this signature in database
GPG Key ID: E61E2F7DC14AB940

View File

@ -53,7 +53,7 @@ dockers:
goarm: ''
# Name of the built binary that should be used.
binary: mybinary
# Docker image name.
# Template of the Docker image name.
image: myuser/myimage
# Skips the docker push. Could be useful if you also do draft releases.
# Defaults to false.
@ -91,6 +91,7 @@ That can be accomplished simply by adding template language in the definition:
```yaml
# .goreleaser.yml
project: foo
dockers:
-
binary: mybinary
@ -99,7 +100,9 @@ dockers:
This will build and public the following images:
- `myuser/mybinary`
- `myuser/foo`
> Learn more about the [name template engine](/templates).
## Keeping docker images updated for current major
@ -130,6 +133,8 @@ This will build and publish the following images:
With these settings you can hopefully push several different docker images
with multiple tags.
> Learn more about the [name template engine](/templates).
## Applying docker build flags
Build flags can be applied using `build_flag_templates`. The flags must be
@ -155,3 +160,5 @@ docker build -t myuser/myimage . \
--label=org.label-schema.version=1.6.4 \
--label=org.label-schema.name=mybinary"
```
> Learn more about the [name template engine](/templates).