I am building a Docker image based on
debian:buster-slim and installing cUrl in this image. According to the recommendations made by Hadolint, I install all packages via
apt-get with the option
--no-install-recommends to avoid the installation of unneeded packages.
Installed in this way, cUrl is not able to get any file via HTTPS due to it is unable to find the "local issues certificate", as shown in the extract from Docker output below.
Does someone know which additional package I have to install to solve this problem?
Step 15/19 : RUN set -ex; curl --output distribution.zip $FULL_URL ---> Running in 9aa176a788d7 + curl --output distribution.zip https://www.host.domain/file.zip % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0 curl: (60) SSL certificate problem: unable to get local issuer certificate More details here: https://curl.haxx.se/docs/sslcerts.html curl failed to verify the legitimacy of the server and therefore could not establish a secure connection to it. To learn more about this situation and how to fix it, please visit the web page mentioned above.
This is my current version of the use Dockerfile:
FROM debian:buster-slim RUN set -ex; apt-get -y update RUN set -ex; \ apt-get -y install --no-install-recommends \ curl=7.64.0-4+deb10u1 \ unzip=6.0-23+deb10u1 \ coreutils=8.30-3 \ lsb-release build-essential ssh-client apt-transport-https \ python gnupg RUN set -ex; curl --output distribution.zip https://www.host.domain/file.zip