-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
podman support #2991
Comments
I would love to see podman support as well. I'm in the process of moving off docker. |
I have just updated the labels to reflect this is a feature request and not a question. |
It appears there is an API for podman that you could use for integration of portainer. I unfortunately just had a baby and do not have the time (nor mental sanity) to dive into building something like this out. |
There is an upcoming Docker compatible API for Podman that could make Portainer integration with Podman much simpler to implement. |
I tried today to run portainer on podman v2.0.1.
In the release post from podman, they mentioned that they only support Docker API v1.40, this version is supported by portainer? |
We had originally added full support for API 1.24.0, however due to a large number of user reported issues around breaking backwards compatibility, we ended up rolling back.
We do support 1.24.0, but its not what i would say is 100% coverage.
Likely in Portainer 2.0 we will enforce 1.24.0 as the 2.0 product already introduces breaking changes, so the upgrade to it should be considered anyway.
N
|
@MrSuicideParrot to clarify, we fully support any Docker endpoint with API version >= 1.37 (docker >= 18.05.x) |
This is because podman handles networking differently than docker. |
Please support podman |
As Podman is Docker API 1.40 compliant, when we release Portainer CE 2.1, which will itself support the latest Docker API (currently we only support an older API ver), we are hopeful this will work.
|
Note we are not committing to podman support, what we are saying is that it might work...
Rgds,
Neil
|
Not strictly true. True out of the box, but I have a RHEL 8 box running docker, it just took a little extra configuration. The big problem is updating docker daemon. That being said, podman is completely compatible in userland to docker. You can "alias docker=podman" and carry on using docker commands, because both are OCI-compliant |
The biggest issue (I imagine) would be that podman is daemonless (native) |
Would this work with Portainer?
Source: https://podman.io/blogs/2020/06/29/podman-v2-announce.html Thanks |
Not quite, https://www.redhat.com/sysadmin/compose-kubernetes-podman:
HTH, |
That doesn't mean it has to use a daemon. That is just an option. I may be wrong on this, but I feel like a vast majority that want to use Podman want to do so because of the daemonless/rootless features. (At least that's my intent) |
Hi @TheEagle13, TNX , |
Everything is working apparently so I found some errors. For example:
Could you try to open this on your portainer? |
Hi @davidbojart indeed not works at 100%. I have the same error. |
hey @deviantony do you know why this got closed? |
@ewoks How about reading the message above the |
@ewoks as said in the last message, you'll find the reason here: #2991 (comment) You can use #5188 for any feedback related to podman support in Portainer. |
Out of curiosity for the users following that thread, are you running rootless Podman or simply running podman with a root account? |
@deviantony rootless in my case. |
@deviantony rootless |
rootless but I tried with a root account and for example on Fedora 35 (Podman 3.4.7) the container stats are not working by the same on rootless. In the images section all images show unused. I tried on Fedora 36 beta with podman 4.0.3 rootless and SELINUX disabled, the stats are working but only Network usage and I/O usage show anything on the graphics. In the images only show unused at the images with no container assigned. |
@davidbojart thanks, I've been experimenting with rootful Podman (4.0.2 on centos 8) and pretty much everything is working as expected:
That's with the latest version of Portainer. I'll be investigating rootless podman soon. |
Sound good!! cpu and memory stats are working ? I tried on centos 8 and RHEL8 with podman 4.0.2 but not shows anything. In rootless: In root: |
@davidbojart my bad, indeed it seems that CPU/MEM are not ok. Will look into the why. |
An update on this topic, following the report format provided by @subaro in #2991 (comment) Tested using Portainer CE 2.13.1 connected to a Portainer agent running version 2.13.1. The agent has been deployed on a rootless podman environment through:
OverviewSetup: Legend Page: Home When visiting the Home page, all Connected Agents and some of their information are displayed. Result:
Page: Dashboard When visiting the Dashboard, information about the selected agent should be displayed.
Page: App templates An arbitrary container is to be started according to an app template. I have taken the example of the nginx for this. I filled all necessary fields.
Page: Containers
Page: Images The images page displays images and their information. Box: Pull images
Box: Images Existing images... Page: Networks The Networks page shows all networks and their settings.
Page: Volumes On the Volumes page, all volumes are displayed.
Events The page displays the events of the socket:
Host The page displays more information about the host:
|
Updated 08/06/2024Tested on Podman 4.9.4 For those interested, here are the different ways to deploy / use Portainer with Podman: Podman root contextFirst make sure to enable the Podman socket:
Run Portainer in a Podman root environment:
Run the Portainer agent in a Podman root environment:
Run the Portainer Edge agent in a Podman root environment:
Podman rootless contextFirst make sure to enable the Podman socket for your user:
Run Portainer in a Podman rootless environment:
Run the Portainer agent in a Podman rootless environment:
Run the Portainer Edge agent in a Podman rootless environment:
|
Thanks Anthony! What is the difference to use the tag alpine or latest? |
@davidbojart woops, I updated the comment above with proper tags. I used alpine for my testing but I'd recommend the latest tag or non-alpine builds for real world/production usage, the images are based on scratch (no shell or binaries embedded therefore less attack surface so are deemed more secure) but alpine images are handy when you're in a need to troubleshoot from within the Portainer container. |
Hi, I'm trying to run portainer on podman as root, but I always get the following error : This happens when I try to run portainer as root. The command I'm trying is: Does someone have a solution ? I found no mention of this error anywhere. I am running this as root on a fresh debian install. |
It's |
@deviantony thank you for your great write up! I followed your instructions but am running into this: #5188 (comment) any thoughts on how to get past this issue? Any help appreciated :)
|
tried getting portainer-agent connected to my rootless podman and having some issues. and seeing the following on the logs:
any ideas what I'm missing? |
Hi! If you want connect to a rootless podman, you need to start rootless service with: systemctl start --user podman.socket and the path would be : "/run/user/1000/podman/podman.sock" Regards, |
* add logging to debug * safely combine hostURL, baseURL * only add base-path for kubeconfig * fix tests * separate internal configs with isInternal --------- Co-authored-by: testa113 <testa113>
Run the Portainer agent in a Podman rootless environment with podman-compose:
|
Some things may have changed in newer releases as I had to change the port 8000 -> 9000. podman run -d -p 9443:9443 -p 9000:9000 --security-opt label=disable --name=portainer --restart=always -v /run/user/$(id -u)/podman/podman.sock:/var/run/docker.sock:Z -v portainer_data:/data portainer/portainer-ce:latest |
I've tested this again on Fedora with Podman 4.9.4 and I have updated the instructions in #2991 (comment) |
Question:
I recently started looking into podman as a possible replacement for docker, as it supports the principle of pods (multiple containers in the same namespace, more resembling the way Kubernetes does it).
Since podman is a daemonless container engine, Portainer itself currently can not be run under it as there is no /var/run/docker.sock that can be accessed for container details.
Are there any plans on supporting podman as the container engine for running Portainer, and supporting the varlink interface for remote podman container engines?
The text was updated successfully, but these errors were encountered: