This documentation is for a release that is no longer maintained
See documentation for the latest supported version 3 or the latest supported version 4.2.5.2.2. 覆盖 source-to-image 构建器镜像脚本
您可以覆盖构建器镜像提供的 assemble、run 和 save-artifacts source-to-image(S2I)脚本。
流程
要覆盖构建器镜像提供的 assemble、run 和 save-artifacts S2I 脚本,请执行以下任一操作:
-
在应用程序源存储库的
.s2i/bin目录中提供assemble、run或save-artifacts脚本。 提供包含脚本的目录的 URL,作为策略定义的一部分。例如:
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - 1
- 此路径会将
run、assemble和save-artifacts附加到其中。如果找到任何或所有脚本,将使用它们代替镜像中提供的同名脚本。
注意
位于 scripts URL 的文件优先于源存储库的 .s2i/bin 中的文件。