Skip to content

Commit

Permalink
Adds info about docker image to README
Browse files Browse the repository at this point in the history
  • Loading branch information
robgonnella committed Dec 28, 2023
1 parent adf94dc commit 75c1804
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 5 deletions.
23 changes: 23 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,29 @@ Some pre-built binaries are provided in the releases section of github:
https://github.com/robgonnella/go-lanscan/releases. These binaries still have
a prerequisite on libpcap being installed first.

# Docker

A docker image is provided with go-lanscan prebuilt.
https://hub.docker.com/r/rgonnella/go-lanscan

See [docker-compose.yml](./docker-compose.yml) for an example setup.

**Linux**

```bash
docker run --rm --network host -v $(pwd)/reports:/reports rgonnella/go-lanscan:latest
```

**MacOS**

On MacOS, host network does not work so you will only be able to scan whatever
docker network the container is in. See
[docker-compose.yml](./docker-compose.yml) for an example.

```bash
docker run --rm -v $(pwd)/reports:/reports rgonnella/go-lanscan:latest
```

### Usage

```bash
Expand Down
11 changes: 6 additions & 5 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,12 @@ services:
go-lanscan_default:

go-lanscan:
build:
args:
- BUILD_TAGS=debug
context: .
dockerfile: Dockerfile
# build:
# args:
# - BUILD_TAGS=debug
# context: .
# dockerfile: Dockerfile
image: rgonnella/go-lanscan:latest
command: --ports 2323,3232 --json
depends_on:
- test-server-1
Expand Down

0 comments on commit 75c1804

Please sign in to comment.