Homework for 13A

Preparation for Afternoon Lecture

Wouldn't it be cool if we could share the projects we're working on with other people? So far, we've only worked with apps in development mode, and running a local server. This afternoon, we'll learn how to put our web apps ON THE WEB!

Up to this point, we have used SQLite as our database. SQLite is an extremely lightweight database, and does not work on production sites. Therefore, if we want to put our rails apps online, we need to switch over to a PostgresSQL database.

Please follow the relevant instructions below to prepare for this afternoon's lecture!

For Mac

Please use Postgres.app and follow the Quick Installation guide. Refer to the documentation if you want more information or help.

Once you've completed the instructions, type in the following commands in your terminal and see if your outputs match the ones below:

$ which psql
/Applications/Postgres.app/Contents/Versions/9.3/bin/psql

$ psql -h localhost
psql (9.3.5)
Type "help" for help.
schneems=# \q

For Linux

In your terminal, run

$ sudo apt-get install postgresql

Once you've completed the instructions, type in the following commands in your terminal and see if your outputs match the ones below:

$ which psql
/usr/bin/psql

$ psql
psql (9.3.5)
Type "help" for help.
maciek# \q

That's it! Get pumped for this afternoon :)

Quick Note

If you run into trouble, don't worry! Installation is pretty tricky and there's a bunch of things that can go wrong depending on how you've configured your laptop. Try googling errors, and if you're still get stuck PM Ian or Erica for help.