Configuration of Weceem is primarily through Grails configuration settings. In Weceem Application these can come from a properties file specified on the command line - but typically they are loaded from Config.groovy in custom Grails applications.
By default Weceem will store files you upload to the repository (e.g. images, CSS and so on) in a folder inside the application's folder on your server. This is not so convenient when upgrading the application, as you often need to duplicate the files manually on the server in the new application's location.
Since 1.0-M1 you can set the location of the upload folder or URL:
// Tell weceem to use a specific path /var/weceem/uploads
weceem.upload.dir = 'file:///var/weceem/uploads'
// or tell weceem to keep it in the application folder, but with a new URL:
weceem.upload.dir = '/weceem_uploads/'
Weceem auto-senses file: URLs in the value and uses that location for the store if it is a file url. If it is not a file url, it assumes it is a new URL path to use when serving the files.
If you do not specify a value for this config variable, Weceem still store the files in <app-dir>/WeceemFiles and they will be served from http://<yourhost>/<yourapppath>/uploads/
By default Weceem maps the content you create into the "root" URI of your application. URLs are formed by "/{space URI alias}/${document URI alias path....}", and having a space with a blank Alias URI allows you to map content into the root URI. To achieve this Weceem has to be rather promiscuous with its URI mapping.
If you do not want this behaviour and would like your own controllers to be accessible with your own Grails URL mappings, you can prefix all content URIs by setting a single Config.groovy setting:
weceem.content.prefix = 'content'
With the above setting for example, all Weceem content will now be accessed under "/content/" e.g: http://localhost:8080/content/About
Weceem has its own non-content controllers that provide publicly-accessible support functionality such as the search, archive and visitor content submission controllers. If you have name clashes with your own controllers, you can prefix these URIs with the following Config.groovy setting:
weceem.tools.prefix = 'wcm-tools'
This will then make sure that all the Weceem tool controllers are accessed like this http://localhost:8080/wcm-tools/search
The Weceem repository and administration UIs may also clash with your URI conventions, or you may have your own "admin" controller that you want at "/admin". To achieve this you can just change the prefix for the Weceem Admin controllers by adding the following to Config.groovy:
weceem.admin.prefix = 'wcm-admin'
This would but the standard Weceem admin interfaces under http://localhost:8080/wcm-admin/
When integrating your own user authentication/authorisation system, you will want the Profile and Log Out links in Weceem admin to point to the relevant functions in your application. You can specify a map of arguments that will be passed to the Grails g:link tag to create the links for these functions, with the following Config.groovy settings:
weceem.profile.url = [controller:'register', action:'edit']
weceem.logout.url = [controller:'logout']
Obviously controller/action etc can be anything you like. You could use any arguments accepted by the Grails linking tags here e.g: uri, url, params, mapping and so on.
If you would like the Weceem Admin pages to fit in better with your application's own styling, you can specify a different layout GSP for it with this Config option:
weceem.admin.layout="mylayout"
This will stop Weceem using its standard "weceemadmin" GSP layout and use yours instead.
You can configure whether or not Weceem should create a default space at startup, as well as what templates are available to the user:
// Turn off default space creation if no spaces found at startup weceem.create.default.space = false // Set the file: or classpath: URL of the default space zip if default creation is ON weceem.default.space.template = "file:/path/to/template.zip"
You can change the list of space templates available to users when they create a new space, by listing them in your Config:
// Set the list of available space templates when a user creates a new space
weceem.space.templates = [
default: "classpath:/org/weceem/resources/default-space-template.zip",
basic:"classpath:/org/weceem/resources/basic-space-template.zip"]
Space templates are regular Weceem export ZIPs, and can reside in the file system (file:) or classpath (classpath:)
Using this mechanism you can hide the default Weceem spaces and restrict the user to your own space templates. This list does not need to include the template for the default space, so you can have a default initial space that is not available to the users themselves.