我在执行docker-compose up
时收到以下错误消息:
ERROR: repository phusionphp not found: does not exist or no pull access
但是我使用docker build -t phusionphp:7.0 .
我可以使用sudo docker run -it --rm phusionphp:7.0
直接运行此代码:
*** Running /etc/my_init.d/00_regen_ssh_host_keys.sh...
*** Running /etc/rc.local...
*** Booting runit daemon...
*** Runit started as PID 9
Jun 16 12:00:57 a62ea0266f66 syslog-ng[15]: syslog-ng starting up; version='3.5.6'
ls
^C*** Shutting down runit daemon (PID 9)...
*** Killing all processes...
搬运工-compose.yaml :
version: '3.1'
services:
php:
image: phusionphp:7
ports:
- 3306:3306
volumes:
- ./data/mariadb:/var/lib/mysql
links:
- mysql
apache:
image: phusionapache
ports:
- 3306:3306
links:
- php
mysql:
image: mysql:5.7
ports:
- 3306:3306
volumes:
- ./data/mariadb:/var/lib/mysql
environment:
MYSQL_USER: "example"
MYSQL_PASSWORD: "example"
MYSQL_ROOT_PASSWORD: "example"
MYSQL_DATABASE: "example"
似乎我有图像,sudo docker images
:
customlamp/phusionphp latest 65221e392f1f 17 minutes ago 317MB
phusionphp 7.0 65221e392f1f 17 minutes ago 317MB
phusionphp 5.6 488fda307f61 27 minutes ago 317MB
phusionphp latest 488fda307f61 27 minutes ago 317MB
customlamp/phusionphp 5.6 488fda307f61 27 minutes ago 317MB
我在这里缺少什么?
答案 0 :(得分:3)
您有图片phusionphp:7.0
因此,请使用整个标记7.0
或不使用最新标记来引用它。
不要仅以7
作为标记来引用它。
所以image: phusionphp:7.0
或image: phusionphp
而不是
image: phusionphp:7