As a DBA and a Linux Hack, I sometimes want to be able to do simple database interactions from the command line. Plus not using Python really annoys Joel. So there's that too. I could never find a straight-up example of how to do a load from a CSV file straight into PostgreSQL using just a BASH script. There may be better ways to do this but hopefully you find this useful.
Sometimes I find myself configuring an internal Linux machine to be able to send emails for alerts or from a particular application. Since this will not be a primary mail server, I just want to rewrite the outgoing address to be something that make sense with the proper domain for the users. Here are the quick steps to accomplish this: