It’s not. Did I miss something? Is there some additional setup neded to start portainer-ce with the other services.
Every container that you want to start after reboot should have the following flag set in the docker-compose.yaml:
restart: always
OR
restart: unless-stopped
For portainer, the 1st one is probably what you want. Most times I use the 2nd though since if I have manually stopped a container, there’s probably a reason and I don’t want it starting on its own.
Does anything need to be added to systemd? I’m using Rocky Linux, son of RedHat.
Dave
Do you remember the command you used to spin up Portainer? I believe a lot of guides have you use docker run
but just wanted to be sure it was docker or docker compose. If you’re using podman instead of docker then it might have something to do with the user account as I’m guessing your containers are running rootless.
I started with Docker but moved to Podman for no good reason. podman run portainer-ce
I found podman_restart-service in Cockpit-services and enabled it. It is off by default. It restarts all services flagged restart always.
Dave
Nice! This took care of your problem then?
The other idea that comes to mind is enabling “linger” for the users when running rootless.
loginctl enable-linger <user>
I don’t know. I also managed to flood / – on another thread looking for ideas for draining the basement.
Dave