设置环境变量在S2i中



当前我正在尝试从我的s2i组装文件设置一个环境变量,例如so

export VARIABLE=some_dynamic_value

当我实际运行由构建器构建的容器时,环境变量不存在。建造者有没有办法动态设置环境变量?

是的,是。您可以将其放入.s2i/environment文件中。如下所述:

https://access.redhat.com/documentation/en-us/openshift_online/3/html/html/html/using_images/source-to-image-image-s2i#dot-net-net-net-net-core-core-core-core-core-configuration

最新更新