andreapollastri / cipi

Install and manage your server like a pro! With Cipi you don’t need to be a Sys Admin to deploy and manage websites and PHP applications powered by cloud VPS.
https://cipi.sh
1.08k stars 223 forks source link

Database (MySQL) on an external host #413

Closed PudlatyPL closed 2 years ago

PudlatyPL commented 2 years ago

Hello, I have question associated with the panel. How to set on external database? I changed mysql addres on .env but nothing has changed, the panel still uses the old one

Alnaggar94 commented 2 years ago

@PudlatyPL I'm looking for the same, have you found a solution?

PudlatyPL commented 2 years ago

@PudlatyPL I'm looking for the same, have you found a solution?

No

andreapollastri commented 2 years ago

Hi! No, Cipi, for security reasons, doesn't let to expose 3306 port externally but you can connect your external client to your DB via SSH tunnel.

Anyway... If you want to open 3306, you can do it manually:

sudo ufw allow 3306/tcp sudo nano /etc/mysql/mysql.conf.d/mysqld.cnf Than...Update bind-address = 127.0.0.1 to bind-address = 0.0.0.0 and Save it! sudo service mysql restart Now your MySql Server is ready to connect from anywhere by your username and password.