Podman run wrapper for common integration use cases

Since rootless podman containers on Silverblue are useful and cool, I ended up building a bunch of images for different things (eg. golang development, vagrant). With a bunch of bash aliases to run these container images interactively and/or transparently.

My bash alias list got pretty big and I noticed it contained a lot of repeating flags for common use cases (eg. volume mounting my homedir, ssh-agent, etc). So I made a little podman run wrapper script: podrunner.sh to handle those cases.

This script holds the podman run arguments required to run your containers with select toolbox like powers. For example if you just want to run a basic Fedora image but with your homedir mapped, just do:

podrunner.sh --homedir -- --rm -it registry.fedoraproject.org/fedora:30

Everything after the -- are just the regular podman run arguments. But the wrapper script will have all the homedirectory related arguments already inserted.

But instead of just a simple base container, what about something more interesting. Like running glxgears from your rootless container:

podrunner.sh --x11 -- --rm jess/glxgears

Or what about VLC with audio and video:

podrunner.sh --x11 --pulseaudio --map-user -- --rm jess/vlc

Shout-out to @jessfraz for the awesome collection of Dockerfiles to play with and test the limits what’s possible :slight_smile:

Cheers!