Docker Community Forums

Share and learn in the Docker community.

docker setup postgis error missing repository

build

#1

setting up django with docker, the docker file looks like this

FROM python:3

ENV PYTHONUNBUFFERED 1
RUN mkdir /code
RUN apt-get update
RUN apt-get install software-properties-common --yes
RUN add-apt-repository ppa:ubuntugis/ubuntugis-unstable
RUN apt-get update
RUN apt-get install postgis
WORKDIR /code
COPY . /code/
RUN pip install -r requirements.txt

among other things it sets up postgis using the ppa ubuntugis

however it throws this error while setting up

Step 5/11 : RUN apt-get install software-properties-common --yes
---> Using cache
---> 634a13159403
Step 6/11 : RUN add-apt-repository ppa:ubuntugis/ubuntugis-unstable
---> Using cache
---> 983fbcf8fd46
Step 7/11 : RUN apt-get update
---> Running in aaf66c98507c
Ign:1 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu disco InRelease
Hit:2 http://security.debian.org/debian-security stretch/updates InRelease
Ign:3 http://deb.debian.org/debian stretch InRelease
Ign:4 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu disco Release
Hit:5 http://deb.debian.org/debian stretch-updates InRelease
Hit:6 http://deb.debian.org/debian stretch Release
Ign:7 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu disco/main amd64 Packages
Ign:8 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu disco/main all Packages
Ign:7 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu disco/main amd64 Packages
Ign:8 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu disco/main all Packages
Ign:7 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu disco/main amd64 Packages
Ign:8 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu disco/main all Packages
Ign:7 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu disco/main amd64 Packages
Ign:8 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu disco/main all Packages
Ign:7 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu disco/main amd64 Packages
Ign:8 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu disco/main all Packages
Err:7 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu disco/main amd64 Packages
404  Not Found
Ign:8 http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu disco/main all Packages
Reading package lists...
W: The repository 'http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu disco Release' does not have a Release file.
E: Failed to fetch http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu/dists/disco/main/binary-amd64/Packages  404  Not Found
E: Some index files failed to download. They have been ignored, or old ones used instead.
ERROR: Service 'web' failed to build: The command '/bin/sh -c apt-get update' returned a non-zero code: 100

it fails to find the repo even though this is how it’s intended to be installed without using docker.

This is using a django projects that works locally and now making it work through docker is the new challenge.