fix keep-userns for systemd service generation
All checks were successful
Podman DDNS Image / build-and-push-ddns (push) Successful in 36s

This commit is contained in:
2025-07-22 19:30:40 -04:00
parent 5184c84d50
commit dae4063f25

View File

@@ -16,13 +16,22 @@ Find and replace minecraft with the name of the service.
### Create the minecraft user
```bash
# As root
useradd minecraft
su - minecraft
# Set the minecraft user password
passwd
# Generate an SSH key for this user. We don't need it now, but it might be handy later.
ssh-keygen
# Exit back to root.
exit
# Optional, copy your authorized_keys into the minecraft user's home dir so you can SSH in.
cp ~/.ssh/authorized_keys /home/minecraft/.ssh/authorized_keys
chown minecraft:minecraft /home/minecraft/.ssh/authorized_keys
# Allow user systemd services to run after you've died (logged out).
loginctl enable-linger $(id -u minecraft)
```
@@ -42,6 +51,7 @@ Create a folder called `quadlets` in your podman_minecraft project.
# Generate the systemd service
podman run \
--security-opt label=disable \
--userns keep-id \
--rm \
-v $(pwd)/active/podman_minecraft:/compose \
-v $(pwd)/active/podman_minecraft/quadlets:/quadlets \