Dockerize 多模块 Maven 项目 [英] Dockerize Multi Module Maven Project

查看:82
本文介绍了Dockerize 多模块 Maven 项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个 Spring Boot 多模块 Maven 项目,我想为每个模块项目制作一个容器.如果可以的话,我如何为每个子模块制作 Dockerfiles?

I have a Spring Boot multi-module Maven project and I want to make a container of each module project. If it is possible to do it, how do I make the Dockerfiles for each sub-module?

推荐答案

这篇文章应该会有所帮助:http://iamsouveek.wordpress.com.与微服务类似,您也可以为模块创建 dockerfile.构建每个工件(例如,如果使用 java 则为 jar)并使用 docker-compose.yml 定义它们的关系

This article should help: http://iamsouveek.wordpress.com. Similar to microservices, you can create dockerfiles for modules as well. Build each artifact(e.g. jar if using java)and define their relations using a docker-compose.yml

这篇关于Dockerize 多模块 Maven 项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆