Skip to content

Commit

Permalink
Add Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
v-byte-cpu committed Apr 4, 2021
1 parent 5051fee commit d73d0c3
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
sx
Dockerfile
.dockerignore
13 changes: 13 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
FROM golang:1.16-alpine as builder

RUN apk add --no-cache libpcap-dev libc-dev gcc linux-headers
ADD . /app
WORKDIR /app
RUN go build -ldflags "-w -s" -o /sx

FROM alpine:3.13

RUN apk add libpcap
COPY --from=builder /sx /sx

ENTRYPOINT ["/sx"]
14 changes: 14 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,20 @@ From the root of the source tree, run:
go build
```

## Docker image

From the root of the source tree, run:

```
docker build -t sx .
```

Start docker container:

```
docker run --rm --net host sx arp 192.168.0.1/24
```

## Quick Start

Here's a quick examples showing how you can scan networks with `sx`.
Expand Down

0 comments on commit d73d0c3

Please sign in to comment.