ubuntu-minimal does not run autoremove
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
diskimage-builder |
Fix Released
|
High
|
Michael Johnson |
Bug Description
At the end of an image build using the "ubuntu-minimal" target "autoremove" is not run because the task is only in the "ubuntu" target. This can leave "build" package dependencies in the image such as gcc. We should move the 99-autoremove task into the ubuntu-common target so that both will run this task and remove dependencies that are no longer required.
For example in an Octavia amphora image build log:
2023-03-20 17:00:14.816 | > The following packages were automatically installed and are no longer required:
2023-03-20 17:00:14.816 | > cpp cpp-11 cpp-12 dctrl-tools gcc-11-base libasan6 libasan8 libatomic1
2023-03-20 17:00:14.816 | > libc-dev-bin libc6-dev libcc1-0 libcrypt-dev libexpat1-dev libgcc-11-dev
2023-03-20 17:00:14.816 | > libgcc-12-dev libgomp1 libisl23 libitm1 libjs-jquery libjs-sphinxdoc
2023-03-20 17:00:14.816 | > libjs-underscore liblsan0 libmpc3 libnsl-dev libpython3-dev libpython3.10
2023-03-20 17:00:14.816 | > libpython3.10-dev libquadmath0 libstdc++-11-dev libtirpc-dev libtsan0
2023-03-20 17:00:14.816 | > libtsan2 libubsan1 linux-libc-dev lto-disabled-list make patch
2023-03-20 17:00:14.816 | > python3.10-dev rpcsvc-proto zlib1g-dev
2023-03-20 17:00:14.816 | > Use 'sudo apt autoremove' to remove them.
This leaves about 1GB of unneeded packages in the image.
Changed in diskimage-builder: | |
assignee: | nobody → Michael Johnson (johnsom) |
Changed in diskimage-builder: | |
importance: | Undecided → High |
Fix proposed to branch: master /review. opendev. org/c/openstack /diskimage- builder/ +/878089
Review: https:/