首页 > 解决方案 > 无法访问 phpmyadmin docker 站点

问题描述

非常令人沮丧的错误。我希望你能给我一些建议。

我删除了所有图像、所有容器,并使用 docker 进行了系统修剪。

然后,我运行以下命令。我知道我没有指定 mysql 主机和密码,但谁在乎,这仍然应该工作或显示我可以登录的 phpmyadmin 主页,它应该说 mysql 无法连接。

sudo docker run --name adminphp1 -d -p 8000:80 phpmyadmin/phpmyadmin.

运行此命令后,查看容器列表,它向我显示以下内容:

389268e87d4b        phpmyadmin/phpmyadmin   "/run.sh supervisord…"   2 minutes ago       Up 2 minutes        9000/tcp, 0.0.0.0:8000->80/tcp   adminphp1

9000/tcp 从何而来?

运行后docker logs adminphp1,显示如下:

Complete! phpMyAdmin has been successfully copied to /var/www/html
/usr/lib/python2.7/site-packages/supervisor/options.py:461: UserWarning: Supervisord is running as root and it is searching for its configuration file in default locations (including its current working directory); you probably want to specify a "-c" argument specifying an absolute path to a configuration file for improved security.
  'Supervisord is running as root and it is searching '
2019-04-11 15:15:09,745 CRIT Supervisor is running as root.  Privileges were not dropped because no user is specified in the config file.  If you intend to run as root, you can set user=root in the config file to avoid this message.
2019-04-11 15:15:09,746 INFO Included extra file "/etc/supervisor.d/nginx.ini" during parsing
2019-04-11 15:15:09,746 INFO Included extra file "/etc/supervisor.d/php.ini" during parsing
2019-04-11 15:15:09,756 INFO RPC interface 'supervisor' initialized
2019-04-11 15:15:09,756 CRIT Server 'unix_http_server' running without any HTTP authentication checking
2019-04-11 15:15:09,756 INFO supervisord started with pid 1
2019-04-11 15:15:10,760 INFO spawned: 'php-fpm' with pid 21
2019-04-11 15:15:10,762 INFO spawned: 'nginx' with pid 22
[11-Apr-2019 15:15:10] NOTICE: fpm is running, pid 21
[11-Apr-2019 15:15:10] NOTICE: ready to handle connections
2019-04-11 15:15:11,826 INFO success: php-fpm entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
2019-04-11 15:15:11,827 INFO success: nginx entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)

然后我尝试使用 website.com:8000 访问它,并且浏览器在考虑了一段时间后显示无法访问该站点。

只是很感激你能提出的任何建议。

标签: mysqldockerphpmyadmin

解决方案


推荐阅读