forked from zeek/zeek-docker
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmaster-dev.Dockerfile
53 lines (38 loc) · 1.51 KB
/
master-dev.Dockerfile
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
43
44
45
46
47
48
49
50
51
52
53
# bro
#
# VERSION 0.1
FROM debian:stretch as builder
MAINTAINER Justin Azoff <[email protected]>
ENV WD /scratch
RUN mkdir ${WD}
WORKDIR /scratch
RUN apt-get update && apt-get upgrade -y && echo 2019-09-21
RUN apt-get -y install build-essential git bison flex gawk cmake swig libssl1.0-dev libmaxminddb-dev libpcap-dev python-dev libcurl4-openssl-dev wget libncurses5-dev ca-certificates zlib1g-dev --no-install-recommends
#Checkout bro
# Build bro
RUN git clone --recursive git://git.bro.org/bro
ADD ./common/gitbro ${WD}/common/gitbro
RUN ${WD}/common/gitbro 1dd0b2e2923f52d5c436df95e7cbcbb789bb33fa Debug
RUN ln -s /usr/local/bro-master /bro
# get geoip data
FROM debian:stretch as geogetter
RUN apt-get update && apt-get -y install wget ca-certificates --no-install-recommends
ADD ./common/getmmdb.sh /usr/local/bin/getmmdb.sh
RUN /usr/local/bin/getmmdb.sh
# Make final image
FROM debian:stretch
ENV VER master
ENV PATH /bro/bin/:$PATH
#install runtime dependencies
RUN apt-get update \
&& apt-get -y install --no-install-recommends libpcap0.8 libssl1.0.2 libmaxminddb0 python2.7-minimal \
python2.7-minimal python-pip python-setuptools python-wheel git \
&& apt-get clean && rm -rf /var/lib/apt/lists/*
COPY --from=builder /usr/local/bro-${VER} /usr/local/bro-master
COPY --from=geogetter /usr/share/GeoIP/* /usr/share/GeoIP/
RUN ln -s /usr/local/bro-${VER} /bro
ADD ./common/bro_profile.sh /etc/profile.d/bro.sh
#install bro-pkg
RUN pip install bro-pkg
RUN bro-pkg autoconfig
CMD /bin/bash -l