diff --git a/Dockerfile.fod.centos.new b/Dockerfile.fod.centos.new index d5ca319ddb004d3223de0888330b42c4e6bdc580..16d184827fa99197997a31c23ac8df01f34a06c6 100644 --- a/Dockerfile.fod.centos.new +++ b/Dockerfile.fod.centos.new @@ -31,24 +31,26 @@ WORKDIR /srv/flowspy ############################### # fod installation step1 -COPY . /srv/flowspy -RUN rm -rf /srv/flowspy/venv +#COPY . /srv/flowspy +#RUN rm -rf /srv/flowspy/venv -COPY install-*.sh requirement*.txt /srv/flowspy/ +COPY install-*.sh requirement*.txt* /srv/flowspy/ # only install system+python deps (for quicker rebuilding by exploiting the docker cache for this step1): #RUN ./install-centos.sh --basesw --here --systemd --systemd_only_install -RUN bash ./install-centos.sh --basesw --here --supervisord +RUN ./install-centos.sh --basesw --here --supervisord ############################### # fod installation step2 +RUN mv /srv/flowspy/venv /srv/flowspy/venv.saved COPY . /srv/flowspy -#RUN rm -rf /srv/flowspy/venv +RUN rm -rf /srv/flowspy/venv +RUN mv /srv/flowspy/venv.saved /srv/flowspy/venv -#RUN bash ./install-centos.sh --fodproper --here --supervisord --setup_admin_user --setup_admin_user5 admin adminpwd admin@localhost.local testpeer 0.0.0.0/0 --exabgp 10.3.10.3 10.3.10.3 1001 10.3.10.10 10.3.10.10 2001 -#RUN bash ./install-centos.sh --both --here --supervisord --setup_admin_user --setup_admin_user5 admin adminpwd admin@localhost.local testpeer 0.0.0.0/0 --exabgp 172.17.0.2 172.17.0.2 1001 172.17.0.3 172.17.0.3 3001 -#RUN bash ./install-centos.sh --both --here --systemd --systemd_only_install --setup_admin_user --setup_admin_user5 admin adminpwd admin@localhost.local testpeer 0.0.0.0/0 # --exabgp 172.17.0.2 172.17.0.2 1001 172.17.0.3 172.17.0.3 3001 +#RUN ./install-centos.sh --fodproper --here --supervisord --setup_admin_user --setup_admin_user5 admin adminpwd admin@localhost.local testpeer 0.0.0.0/0 --exabgp 10.3.10.3 10.3.10.3 1001 10.3.10.10 10.3.10.10 2001 +#RUN ./install-centos.sh --both --here --supervisord --setup_admin_user --setup_admin_user5 admin adminpwd admin@localhost.local testpeer 0.0.0.0/0 --exabgp 172.17.0.2 172.17.0.2 1001 172.17.0.3 172.17.0.3 3001 +#RUN ./install-centos.sh --both --here --systemd --systemd_only_install --setup_admin_user --setup_admin_user5 admin adminpwd admin@localhost.local testpeer 0.0.0.0/0 # --exabgp 172.17.0.2 172.17.0.2 1001 172.17.0.3 172.17.0.3 3001 RUN ./install-centos.sh --fodproper --here --supervisord --setup_admin_user --setup_admin_user5 admin adminpwd admin@localhost.local testpeer 0.0.0.0/0 # --exabgp 172.17.0.2 172.17.0.2 1001 172.17.0.3 172.17.0.3 3001 ############################### diff --git a/Dockerfile.fod.debian b/Dockerfile.fod.debian index 0de94a6bd3715f25c103566347e307ed956085af..ac69c382d769a14551a33d1167a660926863da77 100644 --- a/Dockerfile.fod.debian +++ b/Dockerfile.fod.debian @@ -33,7 +33,7 @@ WORKDIR /srv/flowspy ############################### # fod installation step1 -COPY install-*.sh requirement*.txt /srv/flowspy/ +COPY install-*.sh requirement*.txt* /srv/flowspy/ # only install system+python deps (for quicker rebuilding by exploiting the docker cache for this step1): #RUN ./install-debian.sh --basesw --here --systemd --systemd_only_install @@ -42,8 +42,10 @@ RUN ./install-debian.sh --basesw --here --supervisord ############################### # fod installation step2 +RUN mv /srv/flowspy/venv /srv/flowspy/venv.saved COPY . /srv/flowspy RUN rm -rf /srv/flowspy/venv +RUN mv /srv/flowspy/venv.saved /srv/flowspy/venv # to be sure, try again to install newest deps, i.e., use --both instead of just --fodproper: #RUN ./install-debian.sh --fodproper --here --supervisord --setup_admin_user --setup_admin_user5 admin adminpwd admin@localhost.local testpeer 0.0.0.0/0 --exabgp 10.3.10.3 10.3.10.3 1001 10.3.10.10 10.3.10.10 2001 diff --git a/install-centos.sh b/install-centos.sh index 0ef3282a4fb980717ea1927eb648e31a5359b1b1..41e2ab55e321923e75222c1f407d865f899a58f7 100755 --- a/install-centos.sh +++ b/install-centos.sh @@ -192,6 +192,11 @@ fi venv_dir_base="$(dirname "$venv_dir")" +echo "$0: venv_dir=$venv_dir => venv_dir_base=$venv_dir_base" 1>&2 +ls -dla "$venv_dir" "$venv_dir_base" 1>&2 + +## + static_dir="$fod_dir/static" inst_dir="$(dirname "$0")" @@ -305,7 +310,7 @@ if [ "$install_fodproper" = 0 ]; then echo "Setup partial python environment for FoD" - (ls -la "$venv_dir" 1>&2 || true) + (ls -dla "$venv_dir" 1>&2 || true) if [ -x pyvenv ]; then #pyvenv /srv/venv pyvenv "$venv_dir" @@ -314,6 +319,7 @@ if [ "$install_fodproper" = 0 ]; then virtualenv-3 "$venv_dir" fi ln -sf "$venv_dir" "$fod_dir/venv" + ls -dla "$venv_dir" "$fod_dir/venv" 1>&2 #source /srv/venv/bin/activate source "$venv_dir/bin/activate" @@ -364,6 +370,7 @@ else echo "Setup python environment for FoD" + (ls -dla "$venv_dir" "$fod_dir/venv" "$venv_dir_base" 1>&2 || false) if [ -x pyvenv ]; then #pyvenv /srv/venv pyvenv "$venv_dir" @@ -372,6 +379,7 @@ else virtualenv-3 "$venv_dir" fi ln -sf "$venv_dir" "$fod_dir/venv" + ls -dla "$venv_dir" "$fod_dir/venv" 1>&2 ( set +e diff --git a/requirements-centos.txt b/requirements-centos.txt index 381dde7fe14f172df08013f7c8ec3d0b67cb5e79..15ebbb7948efc9a48c6233871ccb157db5bbecaa 100644 --- a/requirements-centos.txt +++ b/requirements-centos.txt @@ -38,4 +38,3 @@ redis pytest==6.2.5 pytest-django==4.4.0 intervaltree -