简体   繁体   English

如何 dockerize 将要定制的 Web 应用程序?

[英]How to dockerize web application that will be customized?

We ship our web application as WAR file with source code (Java, JSP, Spring config files).我们将 Web 应用程序作为带有源代码(Java、JSP、Spring 配置文件)的 WAR 文件发布。 Our customers customize our application by changing those files.我们的客户通过更改这些文件来定制我们的应用程序。 A Docker image is supposed to be immutable. Docker 映像应该是不可变的。 Is it possible to dockerize our application?可以dockerize我们的应用程序吗?

You can deliver three elements:您可以提供三个要素:

  • one archive representing your sources一份代表您来源的档案
  • one representing your app一个代表您的应用程序
  • one representing a Dockerfiles able to build the first image from the sources, with the sources in its context, able to rebuild the full image.一个代表 Dockerfiles 的 Dockerfiles 能够从源构建第一个图像,源在其上下文中,能够重建完整图像。

For a client, dockerize an application after modifying its sources means rebuilding a docker image.对于客户端,在修改其源后对应用程序进行 dockerize 意味着重建 docker 镜像。

The interest of docker here is that the client doesn't have to know how to build (or what he/she needs to build) your app: everything is configured in the Dockerfile. docker 的兴趣在于客户端不必知道如何构建(或他/她需要构建什么)您的应用程序:一切都在 Dockerfile 中配置。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM