I have a droplet with a docker image hosting Appsmith - a low-code development platform. I want to set up an Appsmith datasource to a MySQL instance on another droplet that is not in the client droplet’s network. I’m not real good at Linux so I definitely need some guidance. I can connect to the server via SSH tunnel from my laptop.
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Heya,
You should be able to do that using a similar approach as to how you would go about when trying to configure access to another MySQL Droplet even when it’s not being inside a docker container.
By default, MySQL is configured to listen for connections only from the local machine. You need to change this so that it can accept connections from your Appsmith droplet.
Also if you do not have a user, create one. Create a user (or use an existing one) and grant privileges. Replace appsmith_user, password, and appsmith_droplet_ip with appropriate values:
CREATE USER 'appsmith_user'@'appsmith_droplet_ip' IDENTIFIED BY 'password'; GRANT ALL PRIVILEGES ON *.* TO 'appsmith_user'@'appsmith_droplet_ip'; FLUSH PRIVILEGES;
If either of your droplets has a firewall enabled, you’ll need to configure it to allow the necessary traffic:
MySQL Server Droplet:
Allow incoming connections on port 3306 (MySQL’s default port) from the Appsmith droplet’s IP address.
Using ufw (Uncomplicated Firewall) as an example:
bashCopy code
sudo ufw allow from appsmith_droplet_ip to any port 3306
Appsmith Droplet:
3306.Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.