<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	
	>
<channel>
	<title>
	Comments on: Adding easy container management to Photon OS with Portainer	</title>
	<atom:link href="https://blog.fjetland.com/2022/05/adding-easy-container-management-to-photon-os-with-portainer/feed/" rel="self" type="application/rss+xml" />
	<link>https://blog.fjetland.com/2022/05/adding-easy-container-management-to-photon-os-with-portainer/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=adding-easy-container-management-to-photon-os-with-portainer</link>
	<description>Notes from the sysadmin trenches, on hobby photography, and anything else that comes to mind</description>
	<lastBuildDate>Fri, 07 Mar 2025 21:36:42 +0000</lastBuildDate>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	
	<item>
		<title>
		By: tomasf		</title>
		<link>https://blog.fjetland.com/2022/05/adding-easy-container-management-to-photon-os-with-portainer/#comment-12068</link>

		<dc:creator><![CDATA[tomasf]]></dc:creator>
		<pubDate>Fri, 07 Mar 2025 21:36:42 +0000</pubDate>
		<guid isPermaLink="false">http://blog.fjetland.com/?p=1424#comment-12068</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://blog.fjetland.com/2022/05/adding-easy-container-management-to-photon-os-with-portainer/#comment-12061&quot;&gt;andrewc&lt;/a&gt;.

Hi andrewc, thanks for reaching out.

It&#039;s a bit hard to say why this happens without knowing more about your setup, but essentially, it sounds like your containers&#039; data storage is not being mapped to persistent storage but stored in memory or on some non-persistent volume.

Most containers that you download from Docker Hub, etc., will have some description of which internal path they recommend mapping to persistent storage like Docker volumes or Bind mounts.

I&#039;m not sure I can be more helpful without knowing more, such as the type of container and the parameters used to deploy it.]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://blog.fjetland.com/2022/05/adding-easy-container-management-to-photon-os-with-portainer/#comment-12061">andrewc</a>.</p>
<p>Hi andrewc, thanks for reaching out.</p>
<p>It&#8217;s a bit hard to say why this happens without knowing more about your setup, but essentially, it sounds like your containers&#8217; data storage is not being mapped to persistent storage but stored in memory or on some non-persistent volume.</p>
<p>Most containers that you download from Docker Hub, etc., will have some description of which internal path they recommend mapping to persistent storage like Docker volumes or Bind mounts.</p>
<p>I&#8217;m not sure I can be more helpful without knowing more, such as the type of container and the parameters used to deploy it.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: andrewc		</title>
		<link>https://blog.fjetland.com/2022/05/adding-easy-container-management-to-photon-os-with-portainer/#comment-12061</link>

		<dc:creator><![CDATA[andrewc]]></dc:creator>
		<pubDate>Fri, 07 Mar 2025 16:30:14 +0000</pubDate>
		<guid isPermaLink="false">http://blog.fjetland.com/?p=1424#comment-12061</guid>

					<description><![CDATA[This might be a bit of a dumb question - but when I reboot my Photon OS server I lose all my container data and they all go back to factory settings - why is this?]]></description>
			<content:encoded><![CDATA[<p>This might be a bit of a dumb question &#8211; but when I reboot my Photon OS server I lose all my container data and they all go back to factory settings &#8211; why is this?</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: tomasf		</title>
		<link>https://blog.fjetland.com/2022/05/adding-easy-container-management-to-photon-os-with-portainer/#comment-4793</link>

		<dc:creator><![CDATA[tomasf]]></dc:creator>
		<pubDate>Thu, 30 Nov 2023 15:44:28 +0000</pubDate>
		<guid isPermaLink="false">http://blog.fjetland.com/?p=1424#comment-4793</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://blog.fjetland.com/2022/05/adding-easy-container-management-to-photon-os-with-portainer/#comment-4785&quot;&gt;Nick&lt;/a&gt;.

Hi Nick, thanks for the question.

Let me jump straight to the second question because I think the way I solved it will help frame how you approach the other two problems.

So, how would you access the container you created? 
My approach is to let the containers remain in the docker network and instead use Traefik for routing and proxying.
So the containers have their own IPs inside the docker network, and for some internal and test services, I&#039;ll just set them up on separate ports on the host&#039;s IP and access them like that. But as you pointed out, running three containers on the same external port wouldn&#039;t work.
For this, especially since most of these cases are web servers that I want to publish externally on port 443, I let Traefik work as a reverse proxy and let it handle all the port settings (mapping 443 to 8888, for example), domain name translation and even SSL cert issuing.
Traefik is powerful but maybe not the easiest to get going with. But alternatives like Caddy and NGINX will do much of the same.

This would be my recommendation to you.

If you still have a specific reason to require separate external IPs, I can only outline how I think it would need to be done, as I haven&#039;t looked into it myself.
First, you must add the IPs to the docker hosts nic or multiple nics.
Then, you would need to define the IP and port mapping for the containers, similar to:
docker run -it -d 198.51.0.4:80:8888 --name web nginx
docker run -it -d 198.51.0.5:80:8888 --name web2 nginx
etc

But I would look into using a reverse proxy/load balancer. It&#039;s a very different way of working from traditional homelab infrastructure, and it&#039;s hard to get your head around, but I think it will be in your best interest in the future.
I hope this was of some help; please let me know if I made no sense at all or if I can help further.]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://blog.fjetland.com/2022/05/adding-easy-container-management-to-photon-os-with-portainer/#comment-4785">Nick</a>.</p>
<p>Hi Nick, thanks for the question.</p>
<p>Let me jump straight to the second question because I think the way I solved it will help frame how you approach the other two problems.</p>
<p>So, how would you access the container you created?<br />
My approach is to let the containers remain in the docker network and instead use Traefik for routing and proxying.<br />
So the containers have their own IPs inside the docker network, and for some internal and test services, I&#8217;ll just set them up on separate ports on the host&#8217;s IP and access them like that. But as you pointed out, running three containers on the same external port wouldn&#8217;t work.<br />
For this, especially since most of these cases are web servers that I want to publish externally on port 443, I let Traefik work as a reverse proxy and let it handle all the port settings (mapping 443 to 8888, for example), domain name translation and even SSL cert issuing.<br />
Traefik is powerful but maybe not the easiest to get going with. But alternatives like Caddy and NGINX will do much of the same.</p>
<p>This would be my recommendation to you.</p>
<p>If you still have a specific reason to require separate external IPs, I can only outline how I think it would need to be done, as I haven&#8217;t looked into it myself.<br />
First, you must add the IPs to the docker hosts nic or multiple nics.<br />
Then, you would need to define the IP and port mapping for the containers, similar to:<br />
docker run -it -d 198.51.0.4:80:8888 &#8211;name web nginx<br />
docker run -it -d 198.51.0.5:80:8888 &#8211;name web2 nginx<br />
etc</p>
<p>But I would look into using a reverse proxy/load balancer. It&#8217;s a very different way of working from traditional homelab infrastructure, and it&#8217;s hard to get your head around, but I think it will be in your best interest in the future.<br />
I hope this was of some help; please let me know if I made no sense at all or if I can help further.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Nick		</title>
		<link>https://blog.fjetland.com/2022/05/adding-easy-container-management-to-photon-os-with-portainer/#comment-4785</link>

		<dc:creator><![CDATA[Nick]]></dc:creator>
		<pubDate>Thu, 30 Nov 2023 03:20:32 +0000</pubDate>
		<guid isPermaLink="false">http://blog.fjetland.com/?p=1424#comment-4785</guid>

					<description><![CDATA[Hi, how do you compose a docker image that has the same network as the host?

I have created a PhotonOS docker using your previous article (https://blog.fjetland.com/2022/05/setting-up-photon-os-4-as-a-docker-host-vm-on-vsphere-7/) where you have defined your docker host as 198.51.0.2

After creating your Portainer, you&#039;d see a bridge and a host if you go to Networks.  The bridge network would be different from the host.  How would you access the container you created?

How do you attach multiple IP addresses to docker host?

I need to setup three servers (using port 8888), so, following your network example, the first docker container would be accessible via https://198.51.0.3:8888, the second docker would be https://198.51.0.4:8888 and the third, https://198.51.0.5:8888

How do I accomplish this?  Any enlightenment is appreciated and thanks in advance.]]></description>
			<content:encoded><![CDATA[<p>Hi, how do you compose a docker image that has the same network as the host?</p>
<p>I have created a PhotonOS docker using your previous article (<a href="https://blog.fjetland.com/2022/05/setting-up-photon-os-4-as-a-docker-host-vm-on-vsphere-7/" rel="ugc">https://blog.fjetland.com/2022/05/setting-up-photon-os-4-as-a-docker-host-vm-on-vsphere-7/</a>) where you have defined your docker host as 198.51.0.2</p>
<p>After creating your Portainer, you&#8217;d see a bridge and a host if you go to Networks.  The bridge network would be different from the host.  How would you access the container you created?</p>
<p>How do you attach multiple IP addresses to docker host?</p>
<p>I need to setup three servers (using port 8888), so, following your network example, the first docker container would be accessible via <a href="https://198.51.0.3:8888" rel="nofollow ugc">https://198.51.0.3:8888</a>, the second docker would be <a href="https://198.51.0.4:8888" rel="nofollow ugc">https://198.51.0.4:8888</a> and the third, <a href="https://198.51.0.5:8888" rel="nofollow ugc">https://198.51.0.5:8888</a></p>
<p>How do I accomplish this?  Any enlightenment is appreciated and thanks in advance.</p>
]]></content:encoded>
		
			</item>
	</channel>
</rss>
