无法使用SSL和mysql2远程连接到WP Engine数据库,具体说明请参见 Setting Remote Database Access
我知道可以进行连接,因为我可以使用Sequel Pro进行连接
ActiveRecord::Base.establish_connection(
adapter: 'mysql2',
host: ENV['MYSQL_HOST'],
username: ENV['MYSQL_USER'],
password: ENV['MYSQL_PASS'],
database: ENV['MYSQL_DB'],
sslverify: true,
sslca: './wpengine_root_ca.pem',
port: 13306
)
发生跟随错误
SSL connection error: error:00000001:lib (0):func(0):reason(1) (Mysql2::Error::ConnectionError)