zenoh-exp/k8s/Dockerfile.wireshark

23 lines
969 B
Docker

FROM docker.io/library/ubuntu:22.04
# Dependencies
RUN echo "wireshark-common wireshark-common/install-setuid boolean true" | debconf-set-selections && \
apt update && \
apt install -y software-properties-common && \
add-apt-repository -y ppa:wireshark-dev/stable && \
apt install -y wireshark-dev tshark && \
apt install -y --allow-change-held-packages wireshark
RUN apt install -y git curl g++ libssl-dev
RUN curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain 1.75.0
RUN useradd -m -s /bin/bash -u 1000 -G wireshark zenoh
# Clone and build
RUN git clone https://github.com/ZettaScaleLabs/zenoh-dissector.git /zenoh && \
cd /zenoh && \
git checkout dev/1.0.0 && \
/bin/bash -c "source $HOME/.cargo/env && cargo build --release"
# Install
USER zenoh
RUN mkdir -p ~/.local/lib/wireshark/plugins/4.4/epan && \
cp /zenoh/target/release/libzenoh_dissector.so ~/.local/lib/wireshark/plugins/4.4/epan/libzenoh_dissector.so