Skip to content

Instantly share code, notes, and snippets.

@honzajavorek
Created July 9, 2012 14:50
Show Gist options
  • Save honzajavorek/3076979 to your computer and use it in GitHub Desktop.
Save honzajavorek/3076979 to your computer and use it in GitHub Desktop.
Setup scripts
#!/bin/bash
echo "LESS installation."
sudo apt-get install python-software-properties
sudo apt-add-repository ppa:chris-lea/node.js
sudo apt-get update
sudo apt-get install nodejs npm
sudo npm install -g less
#!/bin/bash
echo "Creating user dev/development for MySQL."
echo "GRANT ALL ON *.* TO dev@localhost IDENTIFIED BY 'development';" | mysql -u root -p
# http://www.cyberciti.biz/faq/mysql-user-creation/
#!/bin/bash
echo "Creating user dev/development for PostgreSQL."
sudo adduser dev
sudo su - postgres
echo "CREATE USER dev WITH PASSWORD 'development' SUPERUSER;" | psql template1
sudo cp /etc/postgresql/9.1/main/pg_hba.conf /etc/postgresql/9.1/main/pg_hba.conf~
echo "Change 'peer' to 'md5', OK? (enter)"
read
sudo vim /etc/postgresql/9.1/main/pg_hba.conf
sudo service postgresql restart
# http://www.cyberciti.biz/faq/howto-add-postgresql-user-account/
# http://obroll.com/how-to-login-postgresql-access-psql-from-ubuntu-user/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment