I use freehift free level (3 gears). My scalable application uses PHP and MySQL. But the inaccessibility of phpMyAdmin credentials for a scalable 3-gear application makes it difficult to access Mysql table entries. My question is, the forward function of the Openshift function is used to access openshift Mysql through a locally installed phpMyAdmin.
Before opening a session using Putty, go to Connection → SSH → Tunneling.
, 3333. URL- mysql, : 324324343455435435-yourservices.rhcloud.com:44351. "". .
localhost 3333 , , env vars, . Toad Mysql.
, OpenShift PhpMyAdmin.
-, , Redhat (RHC). , : https://www.openshift.com/developers/rhc-client-tools-install.
SSH / . RHC , rhc setup. , SSH- . SSH- . https://www.openshift.com/developers/remote-access.
rhc setup
SSH. OpenShift Putty Windows; https://www.openshift.com/page/install-and-setup-putty-ssh-client-for-windows. , OpenSSH Cygwin, .
Putty SSH- SSH. , env, . , _DB_HOST, _DB_PORT, _DB_USERNAME _DB_PASSWORD, Windows. https://access.redhat.com/site/documentation/en-US/OpenShift_Online/2.0/html/User_Guide/Database_Environment_Variables.html.
env
_DB_HOST
_DB_PORT
_DB_USERNAME
_DB_PASSWORD
, Cygwin ssh. : ssh -f user@my-app.openshift.com -L 3307: DB_HOST: 3306 -N
ssh
user OpenShift, my-app.openshift.com OpenShift DB_HOST IP- ..._DB_HOST, . , 3307 MySQL OpenShift. , PhpMyAdmin 127.0.0.1 , 3307 , env SSH.
user
my-app.openshift.com
DB_HOST
..._DB_HOST
rhc port-forward, : OpenShift: postgresql
instead of phpmyadmin.SQLyog from webyog has an ssh tunnel option. which work great for remote access to openshift mysql
You can add this cartridge to support phpMyAdmin in scalable applications:
https://github.com/arielscarpinelli/openshift-scalable-phpmyadmin