fix docker command permission

This commit is contained in:
ub
2026-02-20 09:56:51 +08:00
parent ba315bb95d
commit 4d4f9cf5c9
2 changed files with 4 additions and 0 deletions

View File

@@ -13,6 +13,7 @@ services:
- ./init.d:/init.d - ./init.d:/init.d
- ./workspace:/workspace - ./workspace:/workspace
- ./root:/root - ./root:/root
- /var/run/user/1000/docker.sock:/var/run/docker-host.sock
ports: ports:
- 58333:8443 - 58333:8443
- 58322:22 - 58322:22

View File

@@ -29,6 +29,9 @@ install -m 0755 -d /etc/apt/keyrings
export DOWNLOAD_URL="https://mirrors.tuna.tsinghua.edu.cn/docker-ce" export DOWNLOAD_URL="https://mirrors.tuna.tsinghua.edu.cn/docker-ce"
curl -fsSL https://raw.githubusercontent.com/docker/docker-install/master/install.sh | sh curl -fsSL https://raw.githubusercontent.com/docker/docker-install/master/install.sh | sh
# Add abc user to docker group
usermod -aG docker abc
mkdir -p /run/sshd mkdir -p /run/sshd
# Configure sshd: allow root login, disable password auth. # Configure sshd: allow root login, disable password auth.