0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

CloudSQLのcloud proxyを使って接続する方法 メモ

0
Posted at

TcpSocketの場合

./cloud_sql_proxy 
-credential_file=credential.json  
-instances=cloudsql-incetance=tcp:3306 &

UnixSocketを使う場合

socketを配置する場所を決める
mdkir /cloudsql && chmod 777 /cloudsql/

setup.sh
PORT=3306
INSTANCE="incetance"
CREDENTIAL="credential.json"
./cloud_sql_proxy -instances=$INSTANCE -credential_file=$CREDENTIAL -dir=/cloudsql &

こんなのを作りました。

確認方法
/cloudsql/instance_nameがあると思います。

sequel proでの接続方法

スクリーンショット 2018-01-23 14.07.43.png
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?