mirror of
https://github.com/gyurix1968/guacamole-client.git
synced 2025-09-06 21:27:40 +00:00
GUACAMOLE-641: Log primary sources of configuration information.
This commit is contained in:
@@ -130,8 +130,9 @@ public class GuacamoleServletContextListener extends GuiceServletContextListener
|
||||
|
||||
// Read configuration information from GUACAMOLE_HOME/guacamole.properties
|
||||
try {
|
||||
environment.addGuacamoleProperties(new FileGuacamoleProperties(
|
||||
new File(environment.getGuacamoleHome(), "guacamole.properties")));
|
||||
File guacProperties = new File(environment.getGuacamoleHome(), "guacamole.properties");
|
||||
environment.addGuacamoleProperties(new FileGuacamoleProperties(guacProperties));
|
||||
logger.info("Read configuration parameters from \"{}\".", guacProperties);
|
||||
}
|
||||
catch (GuacamoleException e) {
|
||||
logger.error("Unable to read guacamole.properties: {}", e.getMessage());
|
||||
@@ -142,8 +143,11 @@ public class GuacamoleServletContextListener extends GuiceServletContextListener
|
||||
// read from system environment if "enable-environment-properties" is
|
||||
// set to "true"
|
||||
try {
|
||||
if (environment.getProperty(ENABLE_ENVIRONMENT_PROPERTIES, false))
|
||||
if (environment.getProperty(ENABLE_ENVIRONMENT_PROPERTIES, false)) {
|
||||
environment.addGuacamoleProperties(new SystemEnvironmentGuacamoleProperties());
|
||||
logger.info("Additional configuration parameters may be read "
|
||||
+ "from environment variables.");
|
||||
}
|
||||
}
|
||||
catch (GuacamoleException e) {
|
||||
logger.error("Unable to configure support for environment properties: {}", e.getMessage());
|
||||
|
Reference in New Issue
Block a user