如何根据命令的输出设置环境variables?
在Dockerfile
:
ENV CLOUD_SDK_REPO="cloud-sdk-$(lsb_release -c -s)"
这不会导致lsb_release -c -s
命令被replace。
RUN export CLOUD_SDK_REPO="cloud-sdk-$(lsb_release -c -s)"
也不行。
我怎样才能达到上述?
在Dockerfile
:
ENV CLOUD_SDK_REPO="cloud-sdk-$(lsb_release -c -s)"
这不会导致lsb_release -c -s
命令被replace。
RUN export CLOUD_SDK_REPO="cloud-sdk-$(lsb_release -c -s)"
也不行。
我怎样才能达到上述?