Apr 10, 2015
At Stanford, we have been preparing to launch our new GeoBlacklight instance, EarthWorks. Over the past few weeks we have had several questions from others about what it takes to deploy GeoBlacklight. This blog post hopes to address these questions. A follow up post will discuss enhancements to this scheme for added functionality.
At its core, GeoBlacklight is a Ruby on Rails application. It depends on having access to two things:
- a relational database
- a Solr index
- used as the search engine for metadata
Simple GeoBlacklight application architecture
EarthWorks is Stanford’s deployment of GeoBlacklight. Our virtualized VMWare infrastructure hosts the application on several load balanced virtual machines. Phusion Passenger and Apache httpd to serve the application from the vm’s. This setup is pretty standard for Ruby on Rails applications in our infrastructure.
If you don’t have a server to deploy the application on you have other options! Because GeoBlacklight is a Ruby on Rails application, there are many options available. You can deploy your application to Heroku, Digital Ocean or other hosting services.
At Stanford we use PostgreSQL for our GeoBlacklight application. This can be configured in the Ruby on Rails application in the
config/database.yml file. While we use PostgreSQL for EarthWorks we also use MySQL for other projects. Blacklight and GeoBlacklight have deployments using PostgreSQL and MySQL. By default, the development environment of GeoBlacklight uses SQLite. SQLite is not recommended for production.
For a comparison between these relations databases, see this extensive tutorial from Digital Ocean.
GeoBlacklight uses Solr for as an index for advanced querying and faceting. Documents indexed into Solr need to be in the geoblacklight-schema format. You can also configure your Solr deployment using the geoblacklight-schema Solr configuration files.
GeoBlacklight requires Solr version 4.7 or later. This hard version rule is due to new advanced spatial support introduced in this release.
The GeoBlacklight software accesses Solr only from the server. This means that you can deploy your Solr server behind a firewall. The front end of the application should never query Solr directly.
That’s all that is needed for a basic GeoBlacklight deployment! I hope this is helpful as you plan your GeoBlacklight deployment. Coming soon, a post on enhancing your GeoBlacklight deployment by adding additional services.
Rails and Blacklight
- Understanding Rails and Blacklight from the Blacklight Wiki
- Configuring Rails Applications from RailsGuides
- Getting Started with Rails 4.x on Heroku from Heroku
- How To Deploy a Rails App with Passenger and Nginx on Ubuntu 14.04 from Digital Ocean
- SQLite vs MySQL vs PostgreSQL: A Comparison Of Relational Database Management Systems from Digital Ocean