Skip to content

Add RUN to the list of supported instructions for environment replacement #17560

Description

@RikiReal

Is this a docs issue?

  • My issue is about the documentation content or website

Type of issue

Information is incorrect

Description

In the Dockerfile reference in the section Environment replacement it says environment variables are not supported by the RUN instruction. However, I tried it in my Dockerfile and it worked.
Also it's used in the source code of e.g. docker-library/golang:
https://github.com/docker-library/golang/blob/db757a0fae9caa7efcd64c120c432e6f83b6eb24/Dockerfile-linux.template#L193

Location

https://docs.docker.com/engine/reference/builder/#environment-replacement

Suggestion

Add RUN to the list of supported instructions for environment variables.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions