I am very new to AWS and Wordpress and am unable to connect to Bitnami MYSQL database server hosted in AWS form R shiny.
I want to access the Mysql database which the wordpress is using to store the data. The wordpress is was installed using Bitnami and hosted in AWS.
The AWS details are as below :
When I SSH to the ip, I get the BITNAMI message with a private IP login:
The PHP Myadmin console shows the following details of the wordpress mysql:
I have created a firewall rule for the port 3306 from the AWS console. Both inbound and outbound have the same setup and accepts traffic from all sources : 0.0.0.0
Now I have created one user from the above mysql console and granted it all the access :
CREATE USER 'r_user'@'localhost' IDENTIFIED BY '1234';
GRANT ALL PRIVILEGES ON * . * TO 'r_user'@'localhost';
Retrieve the data
My R server is hosted in Azure with pubic IP :52.187.238.94
The R code:
library(RMySQL)
> mydb = dbConnect(MySQL(), user='r_user', password='1234',
> dbname='bitnami_wordpress', host='34.221.144.129', port =3306);
I am getting the following error message :
> mydb = dbConnect(MySQL(), user='r_user', password='r_gom', dbname='bitnami_wordpress', host='34.221.144.129', port =3306);
Error in .local(drv, ...) :
Failed to connect to database: Error: Can't connect to MySQL server on '34.221.144.129' (0)
I looked at few post but not able sure if they address the same question : Can't connect to phpmyadmin in Bitnami instance hosted by AWS
Can anyone please help me to connect the Mysql server to R shiny ?