英文:
OpenRewrite: Do we have recipes available for .Docker File change?If not then what approach we should follow to change Docker file through OpenRewrite
问题
通过OpenRewrite更新Docker文件(如果可能)。
我愿意通过OpenRewrite更新Docker文件中的Java版本。
FROM amazoncorretto:17
USER root
RUN yum update -y
RUN yum upgrade -y
RUN yum update -
英文:
docker file update through openrewrite if possible.
I am willing to to update Java version in docker file through OpenRewrite.
**FROM amazoncorretto:17**
USER root
RUN yum update -y
RUN yum upgrade -y
RUN yum update -
------
-----
答案1
得分: 1
我认为纯文本配方是我们目前能做的最好的,直到我们获得一个专门用于Docker的解析器。您可以尝试查找和替换的配方,看它是否适合您的用例:https://docs.openrewrite.org/recipes/text/findandreplace
英文:
I think that plain text recipes is the best we can do here, until we get a dedicated parser for Docker. You could try if the find and replace one fits your use case: https://docs.openrewrite.org/recipes/text/findandreplace
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。


评论