Dockerfile:
ARG BASE_CONTAINER=jupyter/base-notebook
FROM $BASE_CONTAINERARG NB_UID=“888”
ARG NB_GID=“1001”
RUN echo “$NB_USER $NB_UID $NB_GID”
and execute this command:
docker build --no-cache --build-arg NB_UID=888 --build-arg NB_GID=1001 -t test .
Output:
Sending build context to Docker daemon 2.048kB
Step 1/5 : ARG BASE_CONTAINER=jupyter/base-notebook
Step 2/5 : FROM $BASE_CONTAINER
—> 43c995183265
Step 3/5 : ARG NB_UID=“888”
—> Running in eea0dc4efa37
Removing intermediate container eea0dc4efa37
—> e79851088d6c
Step 4/5 : ARG NB_GID=“1001”
—> Running in 10d66f8f506c
Removing intermediate container 10d66f8f506c
—> 7e7787a3c771
Step 5/5 : RUN echo “$NB_USER $NB_UID $NB_GID”
—> Running in 1d83df4e6943
jovyan 1000 100
Removing intermediate container 1d83df4e6943
—> 7712cf85a7d8
Successfully built 7712cf85a7d8
Successfully tagged test:latest
Why is the result of “RUN echo $NB_USER $NB_UID $NB_GID” jovyan 1000 100 not jovyan 888 1001