Passbolt can’t connect to MySQL server, unable to resolve dns?
ERROR 2003 (HY000): Can't connect to MySQL server on 'mysql-service' (111 "Connection refused")
ERROR 2003 (HY000): Can't connect to MySQL server on 'mysql-service.passbolt' (111 "Connection refused")
Tried both as root and as passbolt user
“mysql-service” ClusterIP on port 3306
Happy to post the deployment/services/config/secret yamls if needed
nslookup within container (had to install dnsutils):
root@passbolt-app-64c9584984-65htv:/var/www/passbolt# nslookup mysql-service
- name: passbolt
- name: DATASOURCES_DEFAULT_HOST
- name: DATASOURCES_DEFAULT_DATABASE
- name: DATASOURCES_DEFAULT_USERNAME
- name: DATASOURCES_DEFAULT_PASSWORD
- name: APP_FULL_BASE_URL
- containerPort: 443
- name: mysql
[x] I have read intro post: About the Installation Issues category
[x] I have read the tutorials, help and searched for similar issues
[x] I provide relevant information about my server (component names and versions, etc.)
[x] I provide a copy of my logs and healthcheck
[x] I describe the steps I have taken to trouble shoot the problem
[x] I describe the steps on how to reproduce the issue
Could it be related to a incorrect setting on the mysql service targetPort? It would be nice if you post your service definitions and give some more context.
It looks fine, a long as your mysql deployment uses the same service port and there is no port mapping needed using targetPort.
I’m also assuming you are not using any network policy that is blocking any incoming traffic to the mysql service. Are you able to connect from a different container to your mysql service using the mysql client?
mysql -u passbolt -h mysql-service -p
Had my service incorrectly configured
now I’m just getting a Internal Server Error when going to the url:
(modified the above deployment full app url)
New ticket for this issue?
/usr/lib/python2.7/dist-packages/supervisor/options.py:298: 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 '
2018-08-02 09:12:24,411 CRIT Supervisor running as root (no user in config file)
2018-08-02 09:12:24,427 INFO RPC interface 'supervisor' initialized
2018-08-02 09:12:24,427 CRIT Server 'unix_http_server' running without any HTTP authentication checking
2018-08-02 09:12:24,427 INFO supervisord started with pid 66
2018-08-02 09:12:25,430 INFO spawned: 'php-fpm' with pid 69
2018-08-02 09:12:25,432 INFO spawned: 'nginx' with pid 70
2018-08-02 09:12:25,434 INFO spawned: 'cron' with pid 71
[02-Aug-2018 09:12:25] NOTICE: fpm is running, pid 69
[02-Aug-2018 09:12:25] NOTICE: ready to handle connections
2018-08-02 09:12:26,524 INFO success: php-fpm entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
2018-08-02 09:12:26,525 INFO success: nginx entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
2018-08-02 09:12:26,525 INFO success: cron entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
Glad to see you solved the issue. If you could share what was the problem with your service would be nice for the community.
As per the logs you are posting passbolt container is up and running. Do you see any errors in /var/www/passbolt/logs/error.log ?
My service was looking for the selector label
app: mysql instead of
var/www/passbolt/logs/error.log does not exist, only
Then there are no errors or your passbolt instance is not receiving any requests.
Could you confirm you are getting the expected requests checking /var/log/nginx/access.log (also /var/log/nginx/error.log could help to debug the problem)
both those files are empty
Port: https 443/TCP
NodePort: https 32662/TCP
Session Affinity: None
External Traffic Policy: Cluster
Default backend: default-http-backend:80 (<none>)
Host Path Backends
---- ---- --------
Similar issue here: https://github.com/passbolt/passbolt_docker/issues/95
Just set the ingress to point to 80 and exposed 80 in the service and container deployment