LINUX.ORG.RU

Вопрос про докер

 , ,


0

2

Добрый день. У меня появился вот такой вопрос касательно докера. На машинке установлен убунту 18.10(cosmic) При запуске данного файла

FROM ubuntu:latest
RUN apt-get update && \
    apt-get install libssl-dev -y && \
    apt-get install build-essential -y

Выходит вот такой лог с ошибками:

Sending build context to Docker daemon  2.048kB
Step 1/2 : FROM ubuntu:latest
 ---> 94e814e2efa8
Step 2/2 : RUN apt-get update &&     apt-get install libssl-dev -y &&     apt-get install build-essential -y
 ---> Running in 43160add48ed
Err:1 http://archive.ubuntu.com/ubuntu bionic InRelease
  Temporary failure resolving 'archive.ubuntu.com'
Err:2 http://security.ubuntu.com/ubuntu bionic-security InRelease
  Temporary failure resolving 'security.ubuntu.com'
Err:3 http://archive.ubuntu.com/ubuntu bionic-updates InRelease
  Temporary failure resolving 'archive.ubuntu.com'
Err:4 http://archive.ubuntu.com/ubuntu bionic-backports InRelease
  Temporary failure resolving 'archive.ubuntu.com'
Reading package lists...
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/bionic/InRelease  Temporary failure resolving 'archive.ubuntu.com'
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/bionic-updates/InRelease  Temporary failure resolving 'archive.ubuntu.com'
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/bionic-backports/InRelease  Temporary failure resolving 'archive.ubuntu.com'
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/bionic-security/InRelease  Temporary failure resolving 'security.ubuntu.com'
W: Some index files failed to download. They have been ignored, or old ones used instead.
Reading package lists...
Building dependency tree...
Reading state information...
E: Unable to locate package libssl-dev
The command '/bin/sh -c apt-get update &&     apt-get install libssl-dev -y &&     apt-get install build-essential -y' returned a non-zero code: 100

Подскажите пожалуйста в чем может быть проблема? Из лога видно, что он пытается скачать с bionic, а это версия 18,04.... Не понимаю что нужно делать....пакеты с бионика менял на космик(( пока не помогло(((

systemctl status systemd-resolved.service
mkdir /etc/systemd/resolved.conf.d/
cp /etc/systemd/resolved.conf  /etc/systemd/resolved.conf.d/google.conf
nano /etc/systemd/resolved.conf.d/google.conf -- отредактируй как надо
systemctl restart systemd-resolved.service
iljuase ★★★
()
Последнее исправление: iljuase (всего исправлений: 1)
Ответ на: комментарий от iljuase

Работает оно, к слову, отвратительно, что с DNSSEC и DoTLS, что просто с 8.8.8.8. Кстати, у ТС очень похоже на баг resolved, скорее всего поможет попробовать снова, хотя как это сделать при сборке контейнера - большой вопрос :)

anonymous
()

Добавь в файл /etc/docker/daemon.json

{
    "dns": ["8.8.8.8"]
}

antiZzz
()
Вы не можете добавлять комментарии в эту тему. Тема перемещена в архив.