CAS Toolbox is a tool meant :
- deploying a CAS server into an existing Tomcat installation
- simplifying CAS configuration
- customizing the CAS server
- building quickstart distributions
This package is develop by Esup-portail Consortium
- custom: customization folder
- resources: resources folder, including package dependencies
- update: update folder, containing add-ons to the original JASIG CAS Server
- build.sample.properties: sample deployment config file
- build.xml: ANT build file
- config.sample.properties: simple CAS config file
- Expand cas-toolbox.X-Y.tar.gz
- Rename build.sample.properties to build.properties
- Set the deploy.path property in build.properties
- Rename config.sample.properties to config.properties
- Configure config.properties
- Initialize by running ant init
- Deploy by running ant deploy
- Start Tomcat and browse http://localhost:8080/cas
CAS Toolbox is designed to handle different configuration and/or customization levels.
4 different levels
- The 'update' folder contains the first level of add-ons to the original JASIG CAS Server distribution.
- The 'custom' folder allows to customize every aspect of the CAS Server installation (look and feel, Java sources, configuration files).
- The 'config.properties' files allows to set properties will be used by the CAS Server Spring configuration files.
- CAS Toolbox can handle as many different 'update' folders as you need, one only is required.
In the build.properties file, you can specify a Subversion repository should present an update-XXX folder, used during the initialization step.
You can chain several update folders in the build.properties file:
The order is meaningful: the last update folder always overwrites files from previous updates.
Updates and custom folders
These folders may contain :
- a source folder : java classes that will be compiled and deployed with the original sources
- a webpages folder: other files relative to the Tomcat webapp context in Tomcat (eg : WEB-INF/properties/my.properties)
- deploy.path: the path where files will be deployed.
- config.file: the main configuration file.
Set this property to false the first time you use the init task, allowing Maven to download dependencies. Set it to true with no Internet access.
You can this way customize the update and cutom folders if you don't want to use the default ones.
The config.properties allows to specify your own authentication handlers:
Available handlers are listed in the build.properties file : ldapHandler, fileHandler, jdbcHandler, radiusHandler, etc ...
During the initialization step, this property is used to :
- deploy libraries needed by the handlers used
- deploy specific configuration files xxx-auth.xml (available template files are file-auth.xml, ldap-auth.xml and simpletest-auth.xml).
Specific properties should set in to config.properties (these properties will be used by the specific configuration files of the handlers):
Example for the LDAP handler:
Apart from these specific properties, the file config.properties also contains global properties used by the CAs server itself:
Below is an customization example for the LDAP authentication handler (we want here to add LDAP connection timeouts).
- Copy update/webpages/WEB-INF/ldap-auth.xml to custom/webpages/WEB-INF/ldap-auth.xml
- Edit custom/webpages/WEB-INF/ldap-auth.xml:
- Edit config.properties to set ldap.connect.timeout and ldap.read.timeout properties :
- Run ant init
- Run ant deploy.
Build a quickstart distribution
Once your installation has been customized, CAS Toolbox offers an easy way of building quickstart distributions:
- Edit build.properties and add the following properties (see resources/quickstart/quickstart.properties):
- Run ant _make.quickstart
- Tomcat will be automatically downloaded and embedded into in the package
- The resulting quickstart package is available as build/quickstart/cas-quickstart-X.Y.Z-A.tar.gz
The Esup Update
Esup gives provides an update folder more accurate for French universities.
esup-upadte folder is now include in cas-toolbox.
Other update.XXXX use
- Check the following properties in build.properties:
- Refer to this folder in the update.path property :
- Run ant _get.remoteUpdate
- Folder update.XXXX will be downloaded from subversion
- unzip cas-quickstart-X.Y.Z-Q.tar.gz
- cd cas-quickstart-X.Y.Z-Q
- modify env.cmd (or env.sh)
- launch start.cmd (start.sh)