Is there a way to combine Docker images into 1 container?

前端 未结 7 662
旧时难觅i
旧时难觅i 2020-12-04 14:29

I have a few Dockerfiles right now.

One is for Cassandra 3.5, and it is FROM cassandra:3.5

I also have a Dockerfile for Kafka, but t is quite a

7条回答
  •  广开言路
    2020-12-04 14:43

    You could not combine docker images into 1 container. See the detail discussions in Moby issue, How do I combine several images into one via Dockerfile.

    For your case, it is better to not include the whole Cassandra and Kafka images. The application would only need the Cassandra Scala driver and Kafka Scala driver. The container should include the drivers only.

提交回复
热议问题