LuCI Podman Application

Hi there,

I’ve made my first luci application to manage podman containers. There are two special features for me. One is that if you create a network, an openwrt interface will also be created and added to a firewall zone which is now configurable. Second is that if container has a restart policy it will create a procd service for it to auto boot them. Also possible for existing containers (e.g. if you change the restart policy).

Issues & Feedbacks are welcome!

Thanks to those, it helped and inspired me for this:
OpenWRT - Virtualization Podman
Github - LuCI App Dockerman


Features

  • Container Management: Start, stop, restart, create, remove with live logs, stats, and health monitoring

  • Container Auto-Update: Check for image updates and recreate containers with latest images (see Auto-Update)

  • Import from Run Command: Convert docker run or podman run commands to container configurations

  • Auto-start Support: Automatic init script generation for containers with restart policies

  • Image Management: Pull, remove, inspect images with streaming progress

  • Volume Management: Create, delete, export/import volumes with tar backups

  • Network Management: Bridge, macvlan, ipvlan with VLAN support and optional OpenWrt integration (auto-creates bridge devices, network interfaces, dnsmasq exclusion, and shared podman firewall zone with DNS access rules)

  • Pod Management: Multi-container pods with shared networking

  • Secret Management: Encrypted storage for sensitive data

  • System Overview: Resource usage, disk space, system-wide cleanup

  • Mobile Friendly Lists: Optimized for basic usage

  • OpenWRT JS API: Using luci js api

4 Likes

Hi, thanks for sharing.

I’m having a bit of trouble that I’ve been unable to resolve. I’m using an extroot layer and this seems to be causing some issues but’s I’m way too green to establish what’s resolvable and how.

My priority right now is autostart. I am unable to keep images downloaded in the luci interface (they pull and then never show up in the interface). Images pulled in terminal work fine but do not survive a restart which would be ok (it’s only a 12MB download) except that whatever I try I can’t get the container to launch without pulling it manually.

I’m pulling with a docker-compose.yml

Any help or ideas would be great.

Hi,

I have made a new release, please retry with it. I tested generate autostart script and pulling an image succesfully at OpenWRT 24.10.

Please be aware the following notes:

  • Auto Start script can only be generated if a restart policy is set for the container
  • The image pulling needs some time and streaming from image pulling is a bit laggy so you see a longer time the message "trying to pull image.." and most of the time you see "image pulled succesfully" immediately right after pulling
  • Streaming with OpenWRT jsapi only works if tab is active. So starting image pull and switching the tab will stop the stream. Not a real idea for now how to handle this.

If you do it with a docker composer file just be aware that containers have a restart policy (you also can set it in the container details in the ui) and then you should be able to generate a procd startup script for the container.

If all still not works, even with latest release, please tell me if you see an error in the chrome developer tools and also take a look at the logs (logread) if an error occurs. Also tell me which OpenWRT version you are using, because 25.12 is not really tested from my side yet....

One more question: If you pull the image in the cli, is it visible in the luci UI. Because if you start a container from the cli, both should be displayed in container and images list.

The extroot layer should not be a problem as long as your start scripts are still in /etc/init.d directory and /tmp exists.

cheers

1 Like

Thanks for your reply. Using 24.10.3.

Images pulled from cli show in the luci interface as you would expect them to (in overview, containers and images tabs). I do not think lag has been an issue as the image is small and I have remained on the podman luci tab for some time without the pull showing (though the “successfully pulled” message is displayed). Auto restart is specified in the yml. I will explore a bit more with the new version when I have a little more time.

Thanks again.

1 Like

Just as a short information. I improved a lot of things in the latest version - especially about streaming/volume export and startup script. Before - i used temp files for log streaming and others with a cleanup script. Those things are all gone in the latest version :slight_smile: Also have done some changes in startup script including new feature to regenerate the startup script from the container details.

1 Like

i can’t see an update since 1.11.1

Yeah my message was not up to date with the release date :smiley: i already released it last week but thought yesterday this could be also an interesting information here if you maybe have missed the release :wink:

still not getting an image in the interface in spite of an ‘image pulled successfully’ message

I really have no idea whats happening at your system :thinking: i tried a lot but did not found out any really relevant (tried at three different architectures without any problem)

But i have added in the latest version some kind of a debug mode. There is a uci config file at /etc/config/podman where debug can be enabled. For now this only makes a few checks at the overview page which looks like this:

Also found a helper script had no executable permissions. But i am not sure at which version this was lost because i am pretty sure i already had that one.

And do you use podman volumes? If so maybe you can try to export a not too small volume because this in fact uses a similar mechanism like image pulling.

i am really interested into solving this :smiley: however, job is time expensive too at the moment :wink:

1 Like

i don’t use volumes, no idea how it would benefit me given i only have a single small container running (shairport-sync)

have no idea whats happening at your system

fair enough but i can tell you that i can type any random characters into the podman luci interface in the image field and i get image pulled successfully message