From 83b5349c7ef2f2875cfb98e4166e23cda9517b74 Mon Sep 17 00:00:00 2001 From: Amoelle Date: Fri, 29 Aug 2025 19:03:29 +0300 Subject: [PATCH] update readme --- README.md | 34 +++++++++++++++++++++------------- 1 file changed, 21 insertions(+), 13 deletions(-) diff --git a/README.md b/README.md index dbb638b..fad56ad 100644 --- a/README.md +++ b/README.md @@ -18,13 +18,21 @@ Repository layout (example) Quick start 1. Place challenge files in ./challenge 2. Build and start the lab (background): - docker compose up --build -d + ``` + docker compose up --build -d + ``` 3. Enter an interactive shell inside the running container: - docker compose exec exploit-lab /bin/bash + ``` + docker compose exec exploit-lab /bin/bash + ``` (or as mapped host user) - docker compose exec --user 1000:1000 exploit-lab /bin/bash + ``` + docker compose exec --user 1000:1000 exploit-lab /bin/bash + ``` 4. Stop and remove containers: - docker compose down + ``` + docker compose down + ``` Notes about safety & file locations - Mounted challenge directory is read-only inside the container at /home/kali/challenge. @@ -43,20 +51,20 @@ Typical workflow inside container Rebuilding or updating tools - After editing the Dockerfile, rebuild: - docker compose build --no-cache - docker compose up -d + `docker compose build --no-cache` + `docker compose up -d` Networking - By default runtime network is disabled (network_mode: "none") to reduce risk. If you need network, edit docker-compose.yml and remove or change network_mode, then rebuild. Common commands -- Start foreground (logs): docker compose up --build -- Start background: docker compose up -d -- Exec shell: docker compose exec exploit-lab /bin/bash -- Run one-off shell: docker compose run --rm exploit-lab /bin/bash -- Get logs: docker compose logs -f -- Rebuild image: docker compose build --no-cache -- Stop and remove: docker compose down +- Start foreground (logs): `docker compose up --build` +- Start background: `docker compose up -d` +- Exec shell: `docker compose exec exploit-lab /bin/bash` +- Run one-off shell: `docker compose run --rm exploit-lab /bin/bash` +- Get logs: `docker compose logs -f` +- Rebuild image: `docker compose build --no-cache` +- Stop and remove: `docker compose down` Troubleshooting - Build errors about pip/PEP 668: the Dockerfile uses a Python virtualenv (/opt/venv). If you change Python steps, prefer venv over system pip.