1. install
brew install tor
brew install privoxy
2. copy and modify config file
1. install
brew install tor
brew install privoxy
2. copy and modify config file
Magic words:
psql -U postgresSome interesting flags (to see all, use -h or --help depending on your psql version):
-E: will describe the underlaying queries of the \ commands (cool for learning!)-l: psql will list all databases and then exit (useful if the user you connect with doesn't has a default database, like at AWS RDS)| sudo yum install gcc python27 python27-devel postgresql-devel | |
| sudo curl https://bootstrap.pypa.io/ez_setup.py -o - | sudo python27 | |
| sudo /usr/bin/easy_install-2.7 pip | |
| sudo pip2.7 install psycopg2 |
I use Namecheap.com as a registrar, and they resale SSL Certs from a number of other companies, including Comodo.
These are the steps I went through to set up an SSL cert.
| # Create the datadog user with select only permissions: | |
| # CREATE USER datadog WITH PASSWORD '<complex_password>'; | |
| # | |
| # Grant select permissions on a table or view that you want to monitor: | |
| # GRANT SELECT ON <schema>.<table> TO datadog; | |
| # | |
| # Grant permissions for a specific column on a table or view that you want to monitor: | |
| # GRANT SELECT (id, name) ON <schema>.<table> TO datadog; | |
| # | |
| # Let non-superusers look at pg_stat_activity in a read-only fashon. |
Sublime Text 2 ships with a CLI called subl (why not "sublime", go figure). This utility is hidden in the following folder (assuming you installed Sublime in /Applications like normal folk. If this following line opens Sublime Text for you, then bingo, you're ready.
open /Applications/Sublime\ Text\ 2.app/Contents/SharedSupport/bin/subl
You can find more (official) details about subl here: http://www.sublimetext.com/docs/2/osx_command_line.html
| _complete_ssh_hosts () | |
| { | |
| COMPREPLY=() | |
| cur="${COMP_WORDS[COMP_CWORD]}" | |
| comp_ssh_hosts=`cat ~/.ssh/known_hosts | \ | |
| cut -f 1 -d ' ' | \ | |
| sed -e s/,.*//g | \ | |
| grep -v ^# | \ | |
| uniq | \ | |
| grep -v "\[" ; |
| def format_filename(s): | |
| """Take a string and return a valid filename constructed from the string. | |
| Uses a whitelist approach: any characters not present in valid_chars are | |
| removed. Also spaces are replaced with underscores. | |
| Note: this method may produce invalid filenames such as ``, `.` or `..` | |
| When I use this method I prepend a date string like '2009_01_15_19_46_32_' | |
| and append a file extension like '.txt', so I avoid the potential of using | |
| an invalid filename. | |