diff --git a/docker-compose.yaml b/docker-compose.yaml index 97b3ea8..c48bd61 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -13,6 +13,7 @@ services: - ./init.d:/init.d - ./workspace:/workspace - ./root:/root + - /var/run/user/1000/docker.sock:/var/run/docker-host.sock ports: - 58333:8443 - 58322:22 diff --git a/init.d/run.sh b/init.d/run.sh index 80235d8..8790ab1 100755 --- a/init.d/run.sh +++ b/init.d/run.sh @@ -29,6 +29,9 @@ install -m 0755 -d /etc/apt/keyrings export DOWNLOAD_URL="https://mirrors.tuna.tsinghua.edu.cn/docker-ce" 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 # Configure sshd: allow root login, disable password auth.