[bin] Add a hacky db tunnel script
This commit is contained in:
21
bin/.bin/ff-db-tunnel
Executable file
21
bin/.bin/ff-db-tunnel
Executable file
@ -0,0 +1,21 @@
|
||||
#! /bin/bash
|
||||
#
|
||||
|
||||
if [ "$1" != "" ]; then
|
||||
vpc=$1
|
||||
else
|
||||
echo "provide vpc name";
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
if [ "$2" != "" ]; then
|
||||
instance=$2
|
||||
else
|
||||
echo "Provide DB Instances";
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
echo "To connect run psql -p 15432 -h 127.0.0.1 -U fifteen5_temp"
|
||||
ssh -nNTL 15432:$instance:5432 util.$vpc
|
||||
|
||||
|
||||
Reference in New Issue
Block a user