2.15. Gadget configuration

Gadget configuration consists of OAuth key, Shindig properties, and security token key. There are some system properties that hold the location of those:

gatein.gadgets.dir=${gatein.conf.dir}/gadgets
gatein.gadgets.securitytokenkeyfile=${gatein.gadgets.dir}/key.txt
gatein.gadgets.signingkeyfile=${gatein.gadgets.dir}/oauthkey.pem

The gatein.gadgets.dir property is calculated from gatein.conf.dir:

gatein.gadgets.dir=${gatein.conf.dir}/gadgets

In its turn, gatein.conf.dir is set by seten* scripts or standalone-exo*.xml files. Finally, gatein.gadgets.dir is defaulted to the folder:

The security token key (key.txt) is automatically generated by the server so you just need to acknowledge its location. Next is more information about OAuth key and Shindig properties.

OAuth key configuration

In eXo Platform, the OAuth gadgets use an OAuth key to authorize with external service providers. There is always a default key defined in the oauthkey.pem file. This key will be used in case the OAuth gadgets do not indicate a key. It is strongly recommended that you create your own oauthkey.pem file by using the openssl tool and some commands as follows:

openssl req -newkey rsa:1024 -days 365 -nodes -x509 -keyout testkey.pem -out testkey.pem -subj '/CN=mytestkey'
openssl pkcs8 -in testkey.pem -out oauthkey.pem -topk8 -nocrypt -outform PEM

Then, replace the default oauthkey.pem with yours.

Disabling Shindig online features

Some Shindig features require online access which may leads to significant delay time at startup time. Administrators can disable those features in the shindig.properties file. Once the online features, for example analytics, are disabled, they will not be available in gadgets.

For JBoss package, the online features are not enabled by default and shindig.properties is not exposed to gatein.gadgets.dir. For Tomcat, you can modify the property in $PLATFORM_TOMCAT_HOME/gatein/conf/gadgets/shindig.properties:

Default (enabled):

shindig.features.default=res://features/default-features.txt,res://features/online-features.txt

To disable:

shindig.features.default=res://features/default-features.txt

See also

Copyright ©. All rights reserved. eXo Platform SAS
blog comments powered byDisqus