Skip to content

Instantly share code, notes, and snippets.

View progmult's full-sized avatar
🏠
Working from home

Andrey Kapustin progmult

🏠
Working from home
View GitHub Profile
@progmult
progmult / allow_mysql.sh
Created November 9, 2016 14:37
Allow mysql external connection for IP of current ssh-session (if dynamic ip)
ssh_client_ip=`echo $SSH_CLIENT | awk '{ print $1}'`;
ipfw -q add 00431 allow tcp from $ssh_client_ip to me 3306 in via em0 keep-state