'ssl certificate verify failed when executing a dockerfile

I was making some changes on an existing python app for the company i'm working for, so after cloning the app and opening it in VScode i noticed that the app is in a docker container and to start the app i must use docker-compose build command to build the project and then execute it with docker-compose up. Until now everything is okay, but after somedays i wanted to rebuild the app so i executed a docker-compose build and then i was surprised with some red lines in the terminal when it comes to install the pipenv : enter image description here

i searched online and i found that i should add some flags to the pipenv install line, it worked by this time, but when it comes to install the dependencies i got these errors: enter image description here

Even more, i can't clone any external project ! for example i wanted to clone on of my personal projects on the machine but got this : enter image description here

I'm not sure where the problem is.

anyone have experience with this, thanks in advance!

this is my docker file :

FROM python:3.7

RUN mkdir /data
WORKDIR /data
RUN mkdir agilent

COPY agilent agilent
COPY agilent/prod.ini agilent/config.ini
COPY development.ini /data/
COPY setup.py /data/
COPY Pipfile* /data/
#COPY Pipfile.lock /data/

RUN pip3 install --trusted-host pypi.org --trusted-host files.pythonhosted.org pipenv
RUN cd /data && pipenv install --system --deploy --ignore-pipfile
RUN pip install -e .
RUN python setup.py install
RUN python setup.py develop

CMD ["pserve", "development.ini"]


Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source