Skip to content

Commit

Permalink
Dockerfiles: cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
dschmitz2017 committed Jul 6, 2023
1 parent 8685d99 commit 34a3cd9
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 7 deletions.
3 changes: 2 additions & 1 deletion Dockerfile.fod.debian
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,8 @@ RUN ./install-debian.sh --both --here --supervisord # for later setup of admin u
###############################

# potential standalone re-setup of exabgp later (e.g., to exploit docker build cache for the actual installation step(s) above)
#RUN cd /opt/FOD/ && ./exabgp/run-exabgp-generic --init-conf 10.3.10.3 10.3.10.3 1001 10.3.10.10 10.3.10.12 3001 -- --systemd
##RUN cd /opt/FOD/ && ./exabgp/run-exabgp-generic --init-conf 10.3.10.3 10.3.10.3 1001 10.3.10.10 10.3.10.12 3001 -- --supervisord --enable
#RUN cd /opt/FOD/ && ./exabgp/run-exabgp-generic --init-conf 10.3.10.3 10.3.10.3 1001 10.3.10.10 10.3.10.12 3001 -- --supervisord

#############################################################################
#############################################################################
Expand Down
8 changes: 3 additions & 5 deletions docker-compose/Dockerfile_FOD
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ RUN sed -i -e 's/# en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/' /etc/locale.gen && \
ENV LANG en_US.UTF-8
RUN apt-get update -y && apt-get -o Dpkg::Options::='--force-confdef' -o Dpkg::Options::='--force-confold' --assume-yes -fuy dist-upgrade
RUN apt-get install -y git less man make gcc strace ltrace lsof file vim tshark tcpdump curl wget net-tools sudo psutils procps iptables iputils-ping iputils-tracepath hping3 iproute2 supervisor
RUN useradd exabgp
#RUN useradd exabgp
RUN mkdir -p /var/run/supervisor /opt/FOD
WORKDIR /opt/FOD
EXPOSE 8000
Expand All @@ -17,14 +17,12 @@ EXPOSE 8000
COPY install-debian.sh /opt/FOD
RUN ./install-debian.sh --basesw_os --here__with_venv_relative --supervisord

RUN apt-get install -y pkg-config

# build step2 (exploit docker build cache, only redone if ./install-debian.sh or requirements.txt changed)
COPY requirements.txt /opt/FOD
RUN ./install-debian.sh --basesw_python --here__with_venv_relative --supervisord

# build step3 will be done in first CMD / run
#COPY docker-compose/fod_setup_environment.sh /opt/setup_environment.sh # includes tryinfo to redo step 1 + step 2 again (at least ensure everything is really up-to-date)
# build step3 will be done in CMD (as bind-mount for /opt/FOD is only available during docker run, and not during docker build)
#COPY docker-compose/fod_setup_environment.sh /opt/setup_environment.sh # includes trying to redo step 1 + step 2 again (at least ensure everything is really up-to-date)
#COPY docker-compose/fod_setup_environment.sh /opt/setup_environment.sh # only to the least minimal adaptions necessary in the bind-mounted FOD dir are performed
COPY docker-compose/fod_setup_environment-step3.sh /opt/setup_environment.sh
CMD /opt/setup_environment.sh && supervisord -c docker-compose/fod_supervisord.conf
2 changes: 1 addition & 1 deletion docker-compose/Dockerfile_FOD.1step
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ RUN sed -i -e 's/# en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/' /etc/locale.gen && \
dpkg-reconfigure --frontend=noninteractive locales && \
update-locale LANG=en_US.UTF-8
ENV LANG en_US.UTF-8
COPY docker-compose/fod_setup_environment-1step.sh /opt/setup_environment.sh
RUN mkdir -p /var/run/supervisor
RUN apt-get update -y && apt-get -o Dpkg::Options::='--force-confdef' -o Dpkg::Options::='--force-confold' --assume-yes -fuy dist-upgrade
RUN apt-get install -y git less man make gcc strace ltrace lsof file vim tshark tcpdump curl wget net-tools sudo psutils procps iptables iputils-ping iputils-tracepath hping3 iproute2 supervisor pkg-config
RUN useradd exabgp
WORKDIR /opt/FOD
COPY docker-compose/fod_setup_environment-1step.sh /opt/setup_environment.sh
EXPOSE 8000
CMD /opt/setup_environment.sh && supervisord -c docker-compose/fod_supervisord.conf

0 comments on commit 34a3cd9

Please sign in to comment.