Added configuration files, directories and README information for deployment.

This commit is contained in:
Paul van Tilburg 2011-11-15 15:46:08 +01:00
parent 5e5a9dc13c
commit cfb8fd37ee
4 changed files with 91 additions and 2 deletions

View file

@ -22,13 +22,14 @@ Stop… Camping Time! is a Camping application, so you need:
* Camping (>= 2.1) with
* Active Record (>= 2.3)
* Markaby, and optionally:
* Mongrel
* Mongrel (for testing and deployment without Apache/Rackup)
The following Ruby libraries are required:
* ActionPack (>= 2.3) for ActionView
* ActiveSupport (>= 2.3)
* MIME-Types
* Rack (for deployment using Apache/Rackup)
and the following LaTeX programs:
@ -44,13 +45,92 @@ site-wide deployment yet.
== Usage
Run from the command line:
Stop… Camping Time! can be deployed directly using the Camping server
(which uses Mongrel, or optionally Webrick). This is for simple
deployments or for testing purposes.
Easy deployment via Apache is possible using Phusion Passenger, aka
_mod_rails_ or _mod_rack_ (see See below for the
basic instructions.
Note that this application is a valid Rack application (see and can be deployed by anything that supports
=== Camping Server/Mongrel
Simply run from the command line:
$ camping stoptime.rb
and head over to http://localhost:3301/ to view and use the web
=== Physion Passenger (mod_rails/mod_rack)/Apache
Camping applications are Rack applications. Deployment follows the
standard way of deploying Rack applications using mod_rack.
Stop… Camping Time! additionally needs to have the +xsendfile+
module installed.
*N.B.* Ensure that Apache can, in both types of setups, write in the +db/+
and +public/+ folder.
==== Deployment on a virtual host
Use the following basic configuration:
<VirtualHost *:80>
ServerName some.domain.tld
DocumentRoot /path/to/stoptime/public
<Directory /path/to/stoptime/public>
Allow from all
Options -MultiViews
XSendFile on
Now, restart Apache and visit http://some.domain.tld/.
==== Deployment on a sub URI
For deployment on a sub URI, let us assume there is some virtual host
serving files under +/path/to/document_root+, i.e. something like:
<VirtualHost *:80>
ServerName some.domain.tld
DocumentRoot /path/to/document_root
<Directory /path/to/document_root/
Allow from all
Then, add a symlink from the +public+ subdirectory of to the document
root, e.g.
ln -s /path/to/stoptime/public /path/to/document_root/stoptime
Then, add a +RackBaseURI+ option to the virtual host configuration.
For example:
<VirtualHost *:80>
ServerName some.domain.tld
RackBaseUri /stoptime
<Directory /path/to/document_root/stoptime>
Options -Multiviews
XSendFile on
Now, restart Apache and visit http://some.domain.tld/stoptime.
For more extensive information, please refer to the documentat of
Phusion Passenger:
== License
Stop… Camping Time! is free software; you can redistribute it and/or

9 Normal file
View file

@ -0,0 +1,9 @@
#!/usr/bin/env rackup
require "./stoptime"
StopTime::Models::Base.establish_connection( :adapter => 'sqlite3',
:database => 'db/stoptime.db',
:timeout => 10000 )
run StopTime

db/.placeholder Normal file
View file

tmp/.placeholder Normal file
View file