File tree Expand file tree Collapse file tree
docker-config-engine-stretch Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -73,6 +73,10 @@ RUN apt-get -y install {{ dbg_pkg }}
7373RUN ln /usr/bin/vim.tiny /usr/bin/vim
7474{% - endif %}
7575
76+ # Remove python3.4
77+ # Note: if later python3 is required by more docker images, consider install homebrew python3 here instead of in SNMP image only
78+ RUN apt-get purge -y libpython3.4-minimal
79+
7680# Clean up apt
7781# Remove /var/lib/apt/lists/*, could be obsoleted for derived images
7882RUN apt-get clean -y; apt-get autoclean -y; apt-get autoremove -y
Original file line number Diff line number Diff line change @@ -43,5 +43,5 @@ python-wheels/{{ whl }}{{' '}}
4343{% - endif -%}
4444
4545## Clean up
46- RUN apt-get remove -y python-pip python-dev; apt-get clean -y; apt-get autoclean -y; apt-get autoremove -y
46+ RUN apt-get purge -y python-pip python-dev; apt-get clean -y; apt-get autoclean -y; apt-get autoremove -y
4747RUN rm -rf /debs /python-wheels
Original file line number Diff line number Diff line change @@ -43,5 +43,5 @@ python-wheels/{{ whl }}{{' '}}
4343{% - endif -%}
4444
4545## Clean up
46- RUN apt-get remove -y python-pip python-dev; apt-get clean -y; apt-get autoclean -y; apt-get autoremove -y
46+ RUN apt-get purge -y python-pip python-dev; apt-get clean -y; apt-get autoclean -y; apt-get autoremove -y
4747RUN rm -rf /debs /python-wheels
Original file line number Diff line number Diff line change @@ -35,7 +35,7 @@ RUN pip install /python-wheels/{{ whl }}
3535{% endif %}
3636
3737# Clean up
38- RUN apt-get remove -y python-pip
38+ RUN apt-get purge -y python-pip
3939RUN apt-get clean -y
4040RUN apt-get autoclean -y
4141RUN apt-get autoremove -y
Original file line number Diff line number Diff line change @@ -46,7 +46,7 @@ RUN pip install /python-wheels/{{ whl }}
4646{% endif %}
4747
4848# Clean up
49- RUN apt-get remove -y python-pip
49+ RUN apt-get purge -y python-pip
5050RUN apt-get clean -y
5151RUN apt-get autoclean -y
5252RUN apt-get autoremove -y
Original file line number Diff line number Diff line change @@ -60,7 +60,9 @@ RUN pip install /python-wheels/{{ whl }}
6060RUN python3.6 -m sonic_ax_impl install
6161
6262# Clean up
63- RUN apt-get -y purge libpython3.6-dev curl gcc make libdpkg-perl
63+ RUN apt-get -y purge libpython3.6-dev libpython3.6 curl gcc make libdpkg-perl
64+ # Note: these packages should be removed with autoremove but actually not, so explicitly purged
65+ RUN apt-get -y purge libldap-2.4-2 libsasl2-2 libsasl2-modules libsasl2-modules-db
6466RUN apt-get clean -y && apt-get autoclean -y && apt-get autoremove -y --purge
6567RUN find / | grep -E "__pycache__" | xargs rm -rf
6668RUN rm -rf /debs /python-wheels ~/.cache
Original file line number Diff line number Diff line change @@ -29,9 +29,9 @@ RUN apt-get install -y default-jre
2929RUN apt-get install -y rsyslog psmisc
3030
3131# Remove cffi 1.5.2, will install 1.10.0 by pip later
32- RUN apt-get remove -y python-cffi python-cffi-backend
32+ RUN apt-get purge -y python-cffi python-cffi-backend
3333# Remove pycparser 2.14, will install >=2.17 by pip later
34- RUN apt-get remove -y python-ply python-pycparser
34+ RUN apt-get purge -y python-ply python-pycparser
3535
3636RUN easy_install pip
3737
Original file line number Diff line number Diff line change @@ -311,7 +311,7 @@ sudo LANG=C cp $SCRIPTS_DIR/syncd.sh $FILESYSTEM_ROOT/usr/local/bin/syncd.sh
311311sudo cp $BUILD_TEMPLATES /snmp.timer $FILESYSTEM_ROOT /etc/systemd/system/
312312sudo LANG=C chroot $FILESYSTEM_ROOT systemctl enable snmp.timer
313313
314- sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get remove -y python-dev
314+ sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get purge -y python-dev
315315sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get clean -y
316316sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get autoremove -y
317317
Original file line number Diff line number Diff line change @@ -26,8 +26,8 @@ $(PY3_MIN)_RDEPENDS += $(LIBPY3_MIN)
2626
2727PY3 = $(PYTHON_PNAME ) _$(PYTHON_VER ) _amd64.deb
2828$(eval $(call add_derived_package,$(LIBPY3_MIN),$(PY3)))
29- $(PY3)_DEPENDS += $(PY3_MIN ) $(LIBPY3 )
30- $(PY3)_RDEPENDS += $(PY3_MIN ) $(LIBPY3 ) $( LIBPY3_MIN )
29+ $(PY3)_DEPENDS += $(PY3_MIN ) $(LIBPY3_STD )
30+ $(PY3)_RDEPENDS += $(PY3_MIN ) $(LIBPY3_STD )
3131
3232LIBPY3_DEV = lib$(PYTHON_PNAME ) -dev_$(PYTHON_VER ) _amd64.deb
3333$(eval $(call add_derived_package,$(LIBPY3_MIN),$(LIBPY3_DEV)))
You can’t perform that action at this time.
0 commit comments