Dockerize Virtualmin

Hi,

weird question, but does anyone have a list of all folders that are potentially being modified or used by Virtualmin and Webmin on a Debian 12 system?

Many thanks
Joshua

Depends on if you install minimal or full of course, but you could take a guess at every available webmin module after installation will have altered a config file somewhere. But you could take a list over every file on your system before installation then do the same after installation and look at the differences, you could use du for that and pipe the output to a file, but you add something to your system later that webmin/virtualmin can control there could be extra files added/altered. You need to find someone who has installed everything webmin/virtualmin can manage which is highly unlikely or talk to the devs. That said there are so many options within webmin/virtualmin I doubt they have a full list of every file that can be altered

1 Like

not that weird - but it should’t be that difficult to generate one for yourself. (especially for the GPL version) try creating a new VM and search for files/directories changed since creation.

1 Like

Thank you both @jimr1 @Stegan, I will do that. Was just hoping that someone did this before.

My gual is to dockerize Virtualmin and make it portable with just one folder containing everything.

1 Like

Good luck with that :wink:

1 Like

I’m a little surprized that has not been done before.
(though have to admit I am not a fan of docker) and probably should be done by staff or proposed in “Blue Skies”

Why not go one better and make a TrueNAS App with Virtualmin.

@Stegan @shoulders

Generally I wanna have a portable setup of Virtualmin that will work on nearly any system, I’m familiar with docker so this could work out, even of arm64 (I’ve seen there are some issues with e-mails though).

There shouldn’t be many problems using Debian 12 as base image and installing Virtualmin on top of it.

Joshua

@jimr1 Sounds not so promising, but I will try!

I’ve discussed it a few times in the forum and maybe on the github issue tracker, and the challenges that’ll be involved in making it work.

The challenge is that it’s a lot of stuff. It’s not impossible by any means, but the docker ecosystem isn’t very amenable to piling so many public services into one container.

We have plans in this area, but no firm date…it’ll be during the Virtualmin 8 development cycle, which will begin middle of this year.

1 Like

@Joe - I already spent a lot of time on reading google results. Could you share anything related to this topic?

Docker will give a boost to Virtualmin and I‘m highly interested and making this work! Doesn’t need to be one container. I want to run a docker compose stack. We also need the easy capability to manage docker containers in Virtualmin.

Joshua

It does if you want Virtualmin to manage all the services.

@Joe - even if - let’s get this to docker :slight_smile:

I’m not able to devote time to it in the short-term. But, as I mentioned, it’ll get some attention during the Virtualmin 8 dev cycle later this year, when we’ll be spending more time on cloud native features (e.g. using cloud-based mail relaying, cloud-based DNS, etc.). We may make a set of containers that provides all the services with shared config file directories (or we may not, depends on time and interest). A Virtualmin install that doesn’t deal with mail or DNS is a lot easier to containerize and fits more comfortable into the container model where only a couple of ports and one service is exposed and everything else is contained.

Virtualmin already has most of the bits needed to do that, but not all.

@Joe - please share more details with me. It should me possible to create some sort of containerized environment until your development on this reaches a public testing stage.

Joshua

I think all the web, dns, mailserver ports are required anyway, so why run it in a container?

The bare metal installscript is even easier for me than a docker container.

all you need is a clean install.

You may achieve being OS agnostic but virtualmin uses so many pieces of software you will just end up modifying everything anyway.

I only use docker when it is problematic to setup something in a shared environment.

1 Like

I’m a dinosaur. The one advantage I see for Docker is that it lets maintainers have ONE and ONLY ONE code base to deal with. The staff here could simply say use X and be done with it and be at the same place. They could even roll their own distro. Probably simpler.

2 Likes

Another is its isolated and if say if wordpress in the docker got hacked it can’t effect the server.
I have wordpress on my PC in a docker and its damm slow, hope it better on a linux server.

That makes more sense for the servers than VM. At some point it’s ‘pull the network cable’ followed by ‘pull the power cord’ if you take security to its’ logical conclusion. :wink:

@lawk depending on which technology stack you use, your way is probably the best for most users. just spin up a new Virtualmin and import a backup. For advanced users (and especially sysadmins who usually do not use a CP, like me :P) it’s way more convenient to run software in a docker stack. and the easiest docker way for solo applications is - imo - docker compose.

@stefan1959 yes - but that comes only into game if you actually tune Virtualmin for docker, means Virtualmin will handle it’s very own docker stack and spin up isolated webservers or databases as needed. I do this manually for everything and run every single wordpress in a isolated and highly customized environment (like I mentioned above I don’t like CPs). in my current plan Virtualmin would be inside one massive docker container to keep things easy until the Virtualmin dev’s did what I just explained.

@ID10T I agree