Hello,
I am trying to install Xibo in test environment for now and need some help.
My environment:
RHEL 7.6
Docker version: 18.09.5
MySQL: mysql-community-server-5.7 – Note, MySQL is running on a different machine and it is not a container.
Here is what I did:
On MySQL:
Created database cms – did not create any tables
Created user cms (set password) and did grant all privileges to database cms
From machine running docker; using mysql client, I can connect:
$ mysql -u cms -p -h <DB_Host>
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 198
Server version: 5.7.25 MySQL Community Server (GPL)
Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> show databases;
+--------------------+
| Database |
+--------------------+
| information_schema |
| cms |
+--------------------+
2 rows in set (0.00 sec)
mysql> use cms;
Database changed
mysql> show tables;
Empty set (0.00 sec)
mysql>
On machine running docker:
docker pull xibosignage/xibo-xmr
docker pull xibosignage/xibo-cms
docker run --name xibo-cms-xmr -p 9505:9505 -d xibosignage/xibo-xmr
docker run --name xibo-cms-web -p 80:80 \
-e XMR_HOST=xibo-cms-xmr \
-e CMS_SMTP_SERVER=<SMTP_SERVER>:25 \
-e CMS_SMTP_USE_TLS=NO \
-e CMS_SMTP_USE_STARTTLS=NO \
-e CMS_SMTP_REWRITE_DOMAIN=<REWRITE_DOMAIN> \
-e CMS_SMTP_HOSTNAME=<SMTP_HOSTNAME> \
-e CMS_SMTP_FROM_LINE_OVERRIDE=cms-DoNotReply@<EMAIL_DOMAIN> \
-e CMS_DATABASE_PASSWORD=<MySQLPass> \
-e CMS_DATABASE_HOST=<MYSQL_Host_IP> \
-e CMS_DATABASE_PORT=3306 \
-e CMS_DATABASE_USERNAME=cms \
-e CMS_DATABASE_NAME=cms \
-d -v /mnt/xibo/cms/custom:/var/www/cms/custom -v /mnt/xibo/backup:/var/www/backup -v /mnt/xib/cms/web/theme/custom:/var/www/cms/web/theme/custom \
-v /mnt/xibo/cms/library:/var/www/cms/library -v /mnt/xibo/cms/web/userscripts:/var/www/cms/web/userscripts \
--link xibo-cms-xmr:50001 xibosignage/xibo-cms
Both of the containers get started. When I look at logs for “xibo-cms-xmr”; it does not have anything.
For “xibo-cms-web”, I see:
Waiting for MySQL to start - max 300 seconds
MySQL started
Updating settings.php
ERROR 2002 (HY000): Can't connect to MySQL server on 'mysql' (115)
New install
Provisioning Database
ERROR 2002 (HY000): Can't connect to MySQL server on 'mysql' (115)
Phinx by CakePHP - https://phinx.org. 0.9.2
using config file .varwwwcmsphinx.php
using config parser php
using migration paths
- /var/www/cms/db/migrations
warning no environment specified, defaulting to: production
using adapter mysql
using database cms
[InvalidArgumentException]
There was a problem connecting to the database: SQLSTATE[HY000] [2002] Oper
ation timed out
migrate [-c|--configuration CONFIGURATION] [-p|--parser PARSER] [-e|--environment ENVIRONMENT] [-t|--target TARGET] [-d|--date DATE] [-x|--dry-run]
Configuring Database Settings
ERROR 2002 (HY000): Can't connect to MySQL server on 'mysql' (115)
One thing that looks odd to me is the error line has ‘mysql’ instead of the MySQL hostname specified in “CMS_DATABASE_HOST” variable.
For In the directory /mnt/xibo, I do see directories of “cms” and “backup” that got created.
At this poing I am not sure where to go from here? Any guidance/pointers will be greatly helpful.
Thank you!