mirror of
https://github.com/zeek/zeek.git
synced 2025-10-15 04:58:21 +00:00
Merge branch 'topic/christian/docker-tweaks'
* topic/christian/docker-tweaks: Enable customization of the Docker image's configure invocation Add Python Broker module load test to Docker image btests Set PYTHONPATH in Docker to automatically find Zeek's modules Docker image fix: libpython needs to be 3.9 on Debian Bullseye
This commit is contained in:
commit
dbdd07b93f
6 changed files with 25 additions and 9 deletions
6
.github/workflows/docker.yml
vendored
6
.github/workflows/docker.yml
vendored
|
@ -18,6 +18,7 @@ jobs:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
env:
|
env:
|
||||||
TEST_TAG: zeek:latest
|
TEST_TAG: zeek:latest
|
||||||
|
CONFFLAGS: --generator=Ninja --build-type=Release
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
|
@ -31,7 +32,8 @@ jobs:
|
||||||
with:
|
with:
|
||||||
context: ./
|
context: ./
|
||||||
file: docker/Dockerfile
|
file: docker/Dockerfile
|
||||||
# Load and tag the image so it can be used by the test job below.
|
build-args: |
|
||||||
|
CONFFLAGS=${{ env.CONFFLAGS }}
|
||||||
load: true
|
load: true
|
||||||
tags: ${{ env.TEST_TAG }}
|
tags: ${{ env.TEST_TAG }}
|
||||||
|
|
||||||
|
@ -76,6 +78,8 @@ jobs:
|
||||||
with:
|
with:
|
||||||
context: ./
|
context: ./
|
||||||
file: docker/Dockerfile
|
file: docker/Dockerfile
|
||||||
|
build-args: |
|
||||||
|
CONFFLAGS=${{ env.CONFFLAGS }}
|
||||||
push: true
|
push: true
|
||||||
tags: |
|
tags: |
|
||||||
zeekurity/${{ steps.target.outputs.tag }}
|
zeekurity/${{ steps.target.outputs.tag }}
|
||||||
|
|
10
CHANGES
10
CHANGES
|
@ -1,4 +1,14 @@
|
||||||
|
|
||||||
|
4.2.0-dev.245 | 2021-10-01 14:19:19 -0700
|
||||||
|
|
||||||
|
* Enable customization of the Docker image's configure invocation (Christian Kreibich, Corelight)
|
||||||
|
|
||||||
|
* Add Python Broker module load test to Docker image btests (Christian Kreibich, Corelight)
|
||||||
|
|
||||||
|
* Set PYTHONPATH in Docker to automatically find Zeek's modules (Christian Kreibich, Corelight)
|
||||||
|
|
||||||
|
* Docker image fix: libpython needs to be 3.9 on Debian Bullseye (Christian Kreibich, Corelight)
|
||||||
|
|
||||||
4.2.0-dev.240 | 2021-10-01 13:28:39 -0700
|
4.2.0-dev.240 | 2021-10-01 13:28:39 -0700
|
||||||
|
|
||||||
* Bump highwayhash submodule to pull in another FreeBSD header fix (Christian Kreibich, Corelight)
|
* Bump highwayhash submodule to pull in another FreeBSD header fix (Christian Kreibich, Corelight)
|
||||||
|
|
2
VERSION
2
VERSION
|
@ -1 +1 @@
|
||||||
4.2.0-dev.240
|
4.2.0-dev.245
|
||||||
|
|
|
@ -18,7 +18,7 @@ RUN apt-get -q update \
|
||||||
libz-dev \
|
libz-dev \
|
||||||
make \
|
make \
|
||||||
python3-minimal \
|
python3-minimal \
|
||||||
python3-dev \
|
python3.9-dev \
|
||||||
swig \
|
swig \
|
||||||
ninja-build \
|
ninja-build \
|
||||||
python3-pip \
|
python3-pip \
|
||||||
|
@ -31,11 +31,10 @@ RUN apt-get -q update \
|
||||||
COPY . /src/zeek
|
COPY . /src/zeek
|
||||||
RUN make -C /src/zeek distclean
|
RUN make -C /src/zeek distclean
|
||||||
|
|
||||||
|
ARG CONFFLAGS="--generator=Ninja --build-type=Release"
|
||||||
|
|
||||||
WORKDIR /src/zeek
|
WORKDIR /src/zeek
|
||||||
RUN ./configure \
|
RUN ./configure $CONFFLAGS && ninja -C build install
|
||||||
--generator=Ninja \
|
|
||||||
--build-type=Release \
|
|
||||||
&& ninja -C build install
|
|
||||||
|
|
||||||
# Final layer containing all artifacts.
|
# Final layer containing all artifacts.
|
||||||
FROM debian:bullseye-slim AS final
|
FROM debian:bullseye-slim AS final
|
||||||
|
@ -45,7 +44,7 @@ RUN apt-get -q update \
|
||||||
ca-certificates \
|
ca-certificates \
|
||||||
git \
|
git \
|
||||||
libmaxminddb0 \
|
libmaxminddb0 \
|
||||||
libpython3.7 \
|
libpython3.9 \
|
||||||
libpcap0.8 \
|
libpcap0.8 \
|
||||||
libssl1.1 \
|
libssl1.1 \
|
||||||
libz1 \
|
libz1 \
|
||||||
|
@ -58,3 +57,4 @@ RUN apt-get -q update \
|
||||||
# Copy over Zeek installation.
|
# Copy over Zeek installation.
|
||||||
COPY --from=build /usr/local/zeek /usr/local/zeek
|
COPY --from=build /usr/local/zeek /usr/local/zeek
|
||||||
ENV PATH "/usr/local/zeek/bin:${PATH}"
|
ENV PATH "/usr/local/zeek/bin:${PATH}"
|
||||||
|
ENV PYTHONPATH "/usr/local/zeek/lib/zeek/python:${PYTHONPATH}"
|
||||||
|
|
|
@ -9,5 +9,4 @@ MinVersion = 0.63
|
||||||
[environment]
|
[environment]
|
||||||
LC_ALL=C
|
LC_ALL=C
|
||||||
PATH=%(testbase)s/../../auxil/btest:%(default_path)s
|
PATH=%(testbase)s/../../auxil/btest:%(default_path)s
|
||||||
TEST_IMAGE=${TEST_TAG:-zeek:latest}
|
|
||||||
TZ=UTC
|
TZ=UTC
|
||||||
|
|
|
@ -18,3 +18,6 @@ docker run --rm "${TEST_TAG}" zkg config
|
||||||
|
|
||||||
# Check that a plugin can be installed. We pick any plugin with minimal deps here.
|
# Check that a plugin can be installed. We pick any plugin with minimal deps here.
|
||||||
docker run --rm "${TEST_TAG}" zkg install --force sethhall/domain-tld | sed 's/(.*)/(XXX)/'
|
docker run --rm "${TEST_TAG}" zkg install --force sethhall/domain-tld | sed 's/(.*)/(XXX)/'
|
||||||
|
|
||||||
|
# Check that the Broker Python module loads
|
||||||
|
docker run --rm "${TEST_TAG}" python3 -c "import broker"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue