How to create a rootless instance of PubSub+ in Ubuntu
As a follow on to my previous post announcing the availability of Rootless Containers with Podman, I recorded a quick video showing how easy it is to create a rootless instance of PubSub+ using Podman with Ubuntu 22.04 installed in WSL on my Windows desktop.
With rootless Podman, I was able to create an instance of PubSub+ all in my home directory using a standard non-privileged account with no need for sudo or any other root privilege by the container runtime or otherwise. For developers, this provides an easy way to test their applications against a PubSub+ broker running locally in their standard Linux account.
In the video, I install Podman using the instructions from podman.io and then I followed the procedure I used in my blog to create the rootless instance of PubSub+.
Creating a Rootless Instance of PubSub+ in Ubuntu
Here are some sample command-lines that you can use to get started:
mkdir storage-group podman unshare chown 1000:0 -R /home/<user>/storage-group
podman run -d -u 1000 --shm-size=1g \ -p 8080:8080 -p 55555:55555 -p 1943:1943 -p 1443:1443 -p 9443:9443 \ --env username_admin_globalaccesslevel=admin \ --env username_admin_password=admin \ --net slirp4netns:port_handler=slirp4netns \ --mount type=bind,source=/home/<user>/storage-group,destination=/var/lib/solace,relabel=private,ro=false \ --mount type=bind,source=/home/<user>/solace.pem,destination=/var/run/secrets/solace.pem,relabel=private,ro=false \ --env tls_servercertificate_filepath=/var/run/secrets/solace.pem \ --name solace docker.io/solace/solace-pubsub-standard:edge
curl -k -X POST -d "Hello World" https://localhost:9443/try-me --header "Content-Type: text/plain"