Windows (решено):
Я использую Windows 10 pro, Docker Hub, git bash (только для git clone) и Powershell. Я следовал инструкциям для docker и docker compose для Windows
docker run hello-world отлично работает
Если я запускаю
git clone https://github.com/docker/dockercloud-hello-world
cd dockercloud-hello-world
docker-compose up
Я получаю этот вывод (docker-compose up)
Building helloworld
Step 1/9 : FROM alpine:3.4
---> b7c5ffe56db7
Step 2/9 : RUN apk --update add nginx php5-fpm && mkdir -p /run/nginx
---> Using cache
---> 088033efe014
Step 3/9 : ADD www /www
---> 01d74f229752
Step 4/9 : ADD nginx.conf /etc/nginx/
---> 25a8ff1c84fe
Step 5/9 : ADD php-fpm.conf /etc/php5/php-fpm.conf
---> e35a31afb92b
Step 6/9 : ADD run.sh /run.sh
---> 8147f37e03a4
Step 7/9 : ENV LISTEN_PORT=80
---> Running in 19401a3cf40c
Removing intermediate container 19401a3cf40c
---> 862339058ad5
Step 8/9 : EXPOSE 80
---> Running in 0aadddb5d0d3
Removing intermediate container 0aadddb5d0d3
---> 5ac50ed242ed
Step 9/9 : CMD /run.sh
---> Running in 3ee24385b9d9
Removing intermediate container 3ee24385b9d9
---> 56575ddbc811
Successfully built 56575ddbc811
Successfully tagged dockercloud-hello-world_helloworld:latest
Creating dockercloud-hello-world_helloworld_1 ... done Attaching to dockercloud-hello-world_helloworld_1
helloworld_1 | /bin/sh: /run.sh: not found
dockercloud-hello-world_helloworld_1 exited with code 127
CentOS:
Версия: centos-release-8.0-0.1905.0.9.el8.x86_64
Я следовал за установкой для docker и docker-compose для Linux
sudo docker run hello-world works
Я установил CentOS совершенно новымвнутри Virtualbox 6.0
Если я запускаю
git clone https://github.com/docker/dockercloud-hello-world
cd dockercloud-hello-world
docker-compose up
, я получаю
Building helloworld
Step 1/9 : FROM alpine:3.4
3.4: Pulling from library/alpine
c1e54eec4b57: Downloading [> ] c1e54eec4b57: Downloading [===> ] c1e54eec4b57: Downloading [====> ] c1e54eec4b57: Downloading [========> ] c1e54eec4b57: Downloading [==========> ] c1e54eec4b57: Downloading [============> ] c1e54eec4b57: Downloading [======================> ] c1e54eec4b57: Pull complete
Digest: sha256:b733d4a32c4da6a00a84df2ca32791bb03df95400243648d8c539e7b4cce329c
Status: Downloaded newer image for alpine:3.4
---> b7c5ffe56db7
Step 2/9 : RUN apk --update add nginx php5-fpm && mkdir -p /run/nginx
---> Running in f602999d78c2
fetch http://dl-cdn.alpinelinux.org/alpine/v3.4/main/x86_64/APKINDEX.tar.gz
ERROR: http://dl-cdn.alpinelinux.org/alpine/v3.4/main: temporary error (try again later)
WARNING: Ignoring APKINDEX.167438ca.tar.gz: No such file or directory
fetch http://dl-cdn.alpinelinux.org/alpine/v3.4/community/x86_64/APKINDEX.tar.gz
ERROR: http://dl-cdn.alpinelinux.org/alpine/v3.4/community: temporary error (try again later)
WARNING: Ignoring APKINDEX.a2e6dac0.tar.gz: No such file or directory
ERROR: unsatisfiable constraints:
nginx (missing):
required by: world[nginx]
php5-fpm (missing):
required by: world[php5-fpm]
ERROR: Service 'helloworld' failed to build: The command '/bin/sh -c apk --update add nginx php5-fpm && mkdir -p /run/nginx' returned a non-zero code: 2