0

I want to create an image that contains all the dependencies needed for development like Java Maven, Node, etc., I want to create that image and then deploy it in different PCs at the same time.

I wanted to know if this is possible to do it by using Docker and if you could share with me some guide or information on how to do it, because I want to create an image that contains the dependencies but I want those different to have the software in the image but still remain unique like having their own configuration. I only want the image to deploy a fast environment to program, thanks in advance.

Marc Anthony B
  • 3,635
  • 2
  • 4
  • 19
JcAm
  • 59
  • 1
  • 9
  • What OS do you need to support? Do you want to run your development GUIs / IDE in the container, too? – ciis0 Jul 04 '22 at 15:05
  • win/linux and yes – JcAm Jul 04 '22 at 15:53
  • Does the application you are developing need to run on both OS? Or are just the devs using both? I think running UI applications in containers on Windows is not a well-established path yet. Whats your rationale here? – criztovyl Jul 04 '22 at 19:12

1 Answers1

1

The advantage of docker is that it shares the CLI of the host system while capsule it into its own environment with its own network adapter. That means docker is fast because you don't need to simulate hardware and operation-system as well.

But here comes the clue for you: Since it does no simulate/contain the OS you just can't make it executable on all environments. You need to choose the common way to tell all users that you are using linux containers so you can fullfill unix/mac/... already. For windows users there should be a info that they need WSL (Windows subsystem for linux) installed. Thats where windows can run a linux cli parallel to be compatible as well.

For your dependency: You can build a container or compose that ocntains java, node, ... and all environment stuff - just Docker itself need to be compatible to host by that WSL/linux-container thing.

So now that was a lot about Docker: Same for kubernetes/minicube/... whatever you want to use locally -> of cause you need the correct installation for windows/linux target and if you use linux container and force windows/server to have WSL you can install linux kubernetes as well and be consistant everywhere.

LenglBoy
  • 297
  • 2
  • 8
  • mmm i uderstand what you mean soo in order to create a generic dependency , i have to create a image for windows and an image for linux ? but to install all the images at the same time that can be done by using docker? or do i need to use another kubernetes or so – JcAm Jul 04 '22 at 14:43
  • Yes you can only enforce WSL for win users OR provide win and linux based images at the same time. Then it depends on your target environment which image should be fetched/deployed. You will always just have a unix or win environment so no need to fetch both types at the same time – LenglBoy Jul 04 '22 at 14:52
  • i get it know what i have to do the only thing left to read doc and learn, thanks for the information ! – JcAm Jul 04 '22 at 15:54