Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

How to clone an existing docker (NOT install a second fresh copy)

Featured Replies

Dear all

 

I want to know how I can clone an existing docker so that I have 2 copies of the same docker running.

I DO NOT want to install a fresh copy of the same docker (i have successfully done that by changing the name of the existing docker, and then installing agian using different ports).

I have spent a lot of time and effort to configure a docker running RStudio. Now I want a second copy of that docker, but do not want to spend all that time configuring it again.

 

So, the question is: How can I clone an existing docker so that I have 2 copies of it.

 

Regards

Looking at it objectively

 

  • The name HAS to be different.  No way around it.
  • If you're running in bridge mode, then the PORTS have to be different.  Only one app can listen on a given port at a time
  • If you're running in host mode, then you have to reconfigure the configuration within the app to reference a different port on one of the instances.  (See next point)
  • If the appdata for both instances point to the same config folder, then any config changes on one of the instances takes effect on both of them (ie: negates point above)
  • If you run each app on it's own IP address, then technically yes you could completely share everything (except the name).  BUT, then you would run into a caveat where each app *may* expect to have exclusive access to the appdata, and any changes one makes to it (saving metadata etc) may have unexpected consequences on the other instance since that instance may not be in a state that it will understand why what it assumes is it's appdata (that it assumes it has exclusive access to) suddenly for no reason just up and changed on it.  YMMV

 

  • Author

Hey @Squid. Thanks so much for your inputs!

 

I do understand that the names and ports have to be different. I am happy to do that.

Actually, I also installed a lot of Linux packages in the actual docker itself, so probably just sharing the appdata wont help duplicate the docker (or would it?). 

I do not expect any further changes to the docker, so i don't mind if they are completely independent of each other. I do not want a LIVE clone, just a clone.

This could also maybe be helpful in case someone wants to copy a docker as it is to another system/platform.

 

SO, is there any way (however complicated) to do it?

 

PS: As a side question (off topic, if allowed): if I install a linux package in one docker, does it automatically become available in ALL dockers?

 

Regards

Rishi

  • Author

OK. Will that also take care of any additional packages that were installed in the docker directly via bash?

Depends.  You may have installed them within the docker.img itself (only you can answer that) which isn't the greatest idea to begin with.

 

Any updates to the container, and in this circumstance all of your installations will be lost.

Archived

This topic is now archived and is closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.