forked from praetorian-inc/noseyparker
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.alpine
42 lines (34 loc) · 1.21 KB
/
Dockerfile.alpine
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
################################################################################
# Build `noseyparker`
#
# We use the alpine current, since it's smaller than most debian releases.
################################################################################
FROM rust:alpine AS builder
# Install dependencies
RUN apk add --no-cache --no-interactive \
boost-dev \
build-base \
cmake \
git \
make \
musl-dev \
openssl \
openssl-dev \
perl \
zsh \
&& \
apk cache clean
WORKDIR "/noseyparker"
COPY . .
RUN ./scripts/create-release.zsh --no-debug && \
cp -r release /release
################################################################################
# Build a smaller image just for running the `noseyparker` binary
################################################################################
FROM alpine:latest AS runner
# Add `git` so that noseyparker's git and github integration works
RUN apk add --no-cache --no-interactive git
COPY --from=builder /release /usr/local/
# Tip when running: use a volume mount: `-v "$PWD:/scan"` to make for handling of paths on the command line
WORKDIR "/scan"
ENTRYPOINT ["noseyparker"]