How to get system properties like alfresco.host, share.host, share.port, e.t.c in the webscript?
This code works in the Javascript console, but does not for the webscript.
var ctxt = Packages.org.springframework.web.context.ContextLoader.getCurrentWebApplicationContext();
var properties = ctxt.getBean('global-properties', java.util.Properties);
var protocol = properties["share.protocol"] || 'http';
var host = properties["share.host"] || 'localhost';
var port = properties["share.port"] || '8080'Webscript returns: Packages not defined.