5

I want to redistribute an image containing MySQL and Apache httpd. However, MySQL is GPL-2.0 licensed and Apache httpd is Apache-2.0 licensed. The two licenses are known to be incompatible. Do I have to keep license compatibility as well when redistributing the Docker Image on DockerHub?

  • By containing, do you mean you installed them? – Lucas Ramage Aug 14 at 12:28
  • Yes, it is the image that installed them on the base OS. – Natto Aug 14 at 13:57
2

Docker images are simply portable archives containing the files of an operating system, including configuration files, application binaries, etc.

Per the GPL FAQ,

...if the two programs are combined so that they become effectively two parts of one program, then you can't treat them as two separate programs. So the GPL has to cover the whole thing...If the two programs remain well separated, like the compiler and the kernel, or like an editor and a shell, then you can treat them as two separate programs...

Installing two programs incompatible licenses on a system does not violate the license.

Now the licenses of the Dockerfiles themselves is another matter entirely. A Dockerfile is a source file, and therefore is licensed under the terms of the author.

  • Thank you. I have one more question. Does it violate the license even when the application is created using two packages? For example, I use Mysql and httpd to build a web application on Docker and upload it to DockerHub. – Natto Aug 15 at 3:17
  • No, this would not violate the license. – Lucas Ramage Aug 15 at 3:23
  • When I distribute Docker Image, do I need to pay attention to the license of the installed Package? – Natto Aug 15 at 3:28
  • Not in regards to Docker. If it is an open source package, which freely allows distribution, then you can distribute it in any format you'd like. – Lucas Ramage Aug 15 at 3:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.