diff --git a/compose/compose-file/index.md b/compose/compose-file/index.md index 9d5d9368b030..690be38d1a7e 100644 --- a/compose/compose-file/index.md +++ b/compose/compose-file/index.md @@ -372,6 +372,18 @@ build: target: prod ``` +#### network + +> Added in [version 3.4](compose-versioning.md#version-34) file format + +Build the image inside the specified network, Docker doesn't resolve the project name for the build network, it should be specified explicitly `` -> `_` + +```yaml +build: + context: . + network: example_default +``` + ### cap_add, cap_drop Add or drop container capabilities.