Specify the Liberty configuration with dropins files using developer tools
We can specify the server configuration for Liberty by creating configuration dropins files and placing these files in the configDropins directory.
We can use the dropins files to set a default configuration, or override configurations that are set in server.xml or included files. The server configuration validator includes configuration dropins files as part of the overall server configuration validation. The server configuration editor shows variables and references defined in dropins files in the appropriate content assistance and drop-down lists.
We can place configuration dropins files in either...
- ${server.config.dir}/configDropins/defaults
The configuration is applied before the server configuration. The files are overridden by server.xml or included files.
- ${server.config.dir}/configDropins/overrides
The configuration is applied after the server configuration. The files override server.xml or included files.
See: Use the configuration dropins folder to specify server configuration.
Steps
- To create a configuration dropins file, right-click the server in the Servers view.
- Complete one of the following options:
- To create a configuration dropins file in the defaults directory, select New > Configuration Dropins File > Defaults
- To create a configuration dropins file in the overrides directory, select New > Configuration Dropins File > Overrides.
- Enter the name of the file we want to create.
- Click OK.
The new file is displayed.
- To see the merged configuration, complete one of the following options:
- Right-click server.xml in the Enterprise Explorer or Project Explorer view, and then select Liberty > Open Merged View.
- In the Servers view, right-click on Server Configuration and select Open Merged View.
The merged view of the server configuration shows the defaults at the beginning of the merged configuration. It also shows the overrides at the end of the merged configuration.