Add more firewall rules
This commit is contained in:
15
files/rke-common/usr/libexec/rke2/create_rke_user.sh
Executable file
15
files/rke-common/usr/libexec/rke2/create_rke_user.sh
Executable file
@@ -0,0 +1,15 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Check if user 'rke' exists
|
||||
if ! id -u rke &> /dev/null; then
|
||||
echo "Creating user 'rke'"
|
||||
# Create user 'rke' with home directory using useradd
|
||||
useradd --system -m -k /usr/libexec/rke2/skel/ rke
|
||||
fi
|
||||
|
||||
# Add 'rke' to docker group
|
||||
echo "Adding 'rke' to docker group"
|
||||
usermod -aG docker rke
|
||||
usermod -aG systemd-journal rke
|
||||
|
||||
echo "Done"
|
||||
Reference in New Issue
Block a user