In docker Build, how to send the parameters to the inside of the container is the inside of the container, not Docker

  docker, question

In docker Build, how to send the parameters to the container inside is not the Docker. For example, I have an environment variable in Docker, which is not set. During compilation, different operations are performed to generate the image I specify according to the different parameters. It is not necessary to write the configuration for each different version.

Dockerfile internal writingARG, and thendocker build --build-arg