This is solely a REST API. The android app talks to this.
We are using PostgresSQL with PostGIS extensions for better geospatial indexing and querying capabilities.
The query used to find the closest parking spot, and the code to add the index for fast lookup were borrowed from this blog.
Docker depends on low-level functionality within the Linux kernel, and it does not work natively on Windows or Mac OSX. Fear not, docker toolbox provides a seamless experience via a virtual machine. Install that and everything should be smooth sailing from there.
Ruby is obviously needed. I recommend rvm for managing ruby versions.
So that people don't have to spend time installing stuff I dockerized the app itself.
Download docker and docker-compose. The choice to use docker was that it just works and is easily replicated. Only one person should need to spend time setting things up like this.
Once you have done this:
simply type (or copy/paste):
$ docker-compose build web && docker-compose up -d ; bundle exec rake db:create db:migate
The last commands only need to be run initially and when schema changes occur.
If running the rails server outside of docker and/or Heroku (both of these take care of this detail):
Copy .env.example
to .env
and add the ip or hostname of the development postgres server. DO NOT store this in Git. For now, nothing sensitive is in it, but that may change.
Then just work as you would.