Applications consist of static data, CGI scripts, Rack applications, and a single Puma application (the board agenda, which has some unique response time requirements), and cron jobs.
The goal is to make it so that every committer on the Whimsy PMC can both deploy changes and new applications. A new VM has been provisioned for this purpose: https://whimsy-test.apache.org/.
Static content is working. Changes pushed to GitHub master will be automatically deployed every 30 minutes. Note that this includes the contents of scripts and applications too.
CGI scripts are working, and any dependencies listed in a
Gemfile will automatically be installed. A simple CGI:
Many CGI scripts will require user authentication. This is done by adding a single line to the deployment data identifying the location of the script:
Note that the LDAP module does not currently handle boolean conditions (example: members or officers). The way to handle this is to do authentication in two passes. The first pass will be done by the Apache web server, and verify that the user is a part of the most inclusive group (typically: committers). The CGI scripts that need to do more will need to perform additional checks, and output a “Status: 401 Unauthorized” as the first line of their output if access to this tool is not permitted for the user.
Rack applications are working and run under Passenger under Apache httpd. Again,
Gemfiles are used to specify dependencies. In addition to simply checking the application, one line per passenger application needs to be added to the deployment data:
A simple rack application (two empty directories, and a one line file):
Authentication requirements will also need to be two phase, like with CGI above; but more common conditions can be handled at the “Rack” level instead of at the application level making use of Rack middleware such as:
The board agenda application is an eample of a complete tool that makes extensive use of the library factoring, has a suite of test cases, and client componentization (using ReactJS), and provides instructions for setting up both a Docker component and a Vagrant VM.