Hi,
In image "3.9.5-slim-buster", the command make seems not existing (using during app running).
Event if it is installed here.
Tried to install it manually :
apt-get install make
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package make
But not working.
Thanks for your help.
Emilie
Well. Make is part of the package buuld-essentials. The difference between buster and slim-buster is what? Slim does not contain the build-essentials. So by using the slim-image you castrated yourself to run make.
Solution: use the regular buster-image.
For the slim Dockerfile those packages that get installed are required to build Python and are only installed temporarily, they get removed shortly after
https://github.com/docker-library/python/blob/d0e3ae7cfb4e04978f87a9c95d4c296ee8ac8696/3.9/buster/slim/Dockerfile#L99
The docs has a section describing the variants https://github.com/docker-library/docs/tree/master/python#image-variants
To install the package you'll have to populate the repository lists with an apt-get update first
$ docker run -it --rm python:3.9.5-slim bash
root@7b59ced2b9a3:/# apt update
Get:1 http://security.debian.org/debian-security buster/updates InRelease [65.4 kB]
Get:2 http://deb.debian.org/debian buster InRelease [121 kB]
Get:3 http://deb.debian.org/debian buster-updates InRelease [51.9 kB]
Get:4 http://security.debian.org/debian-security buster/updates/main amd64 Packages [286 kB]
Get:5 http://deb.debian.org/debian buster/main amd64 Packages [7907 kB]
Get:6 http://deb.debian.org/debian buster-updates/main amd64 Packages [10.9 kB]
Fetched 8442 kB in 2s (4050 kB/s)
Reading package lists... Done
Building dependency tree
Reading state information... Done
2 packages can be upgraded. Run 'apt list --upgradable' to see them.
root@7b59ced2b9a3:/# apt install make
Reading package lists... Done
Building dependency tree
Reading state information... Done
Suggested packages:
make-doc
The following NEW packages will be installed:
make
0 upgraded, 1 newly installed, 0 to remove and 2 not upgraded.
Need to get 341 kB of archives.
After this operation, 1327 kB of additional disk space will be used.
Get:1 http://deb.debian.org/debian buster/main amd64 make amd64 4.2.1-1.2 [341 kB]
Fetched 341 kB in 0s (14.1 MB/s)
debconf: delaying package configuration, since apt-utils is not installed
Selecting previously unselected package make.
(Reading database ... 6840 files and directories currently installed.)
Preparing to unpack .../make_4.2.1-1.2_amd64.deb ...
Unpacking make (4.2.1-1.2) ...
Setting up make (4.2.1-1.2) ...
@Uzlopak @wglambert thanks for you answer and sorry for disruption.
Most helpful comment
Well. Make is part of the package buuld-essentials. The difference between buster and slim-buster is what? Slim does not contain the build-essentials. So by using the slim-image you castrated yourself to run make.
Solution: use the regular buster-image.