Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(docker): update Dockerfile to make nipe work in containers #169

Merged
merged 1 commit into from
Jul 8, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 16 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,25 @@ FROM ubuntu:latest
COPY . /usr/src/nipe
WORKDIR /usr/src/nipe

EXPOSE 9050
EXPOSE 9050 9061

RUN apt-get update && \
apt-get install -y cpanminus && \
apt-get install -y libssl-dev && \
apt-get install -y libnet-ssleay-perl && \
apt-get install -y libcrypt-ssleay-perl && \
apt-get install -y tor && \
apt-get install -y iptables && \
rm -rf /var/lib/apt/lists/*

RUN cpanm --installdeps .
RUN perl nipe.pl install

RUN chmod +x nipe.pl

# docker run -d -it --privileged --cap-add=NET_ADMIN nipe
# OR
# docker run -d -it --name nipe-container --privileged --cap-add=NET_ADMIN nipe
# THEN
# docker exec -it <container_id> ./nipe.pl <command>

ENTRYPOINT ["/bin/bash"]