Class CmsAutoSetupProperties
Note that each property set in the file is overwritten if the identical property is set as Java system property (what is used, e.g., by the setup wizard).
Moreover, the property setup.install.components
can be set via an accordingly named environment variable.
- Since:
- 6.0.0
-
Field Summary
Modifier and TypeFieldDescriptionstatic final org.apache.commons.logging.Log
The log object for this class.static final String
The DB connection string parameters property name.static final String
The property keydb.connection.url
for providing the JDBC connection string, e.g.,jdbc:mysql://localhost:3306/
for the default MySQL installation.static final String
The property keydb.create.db
for specifying if the database should be created during the setup.static final String
The property keydb.create.pwd
for specifying the password for the database user that is used during the setup connection.static final String
The property keydb.create.tables
for specifying if the database tables in the OpenCms database should be created.static final String
The property keydb.create.user
for specifying the name of the database user that is used during the setup connection.static final String
The property keydb.default.tablespace
necessary dependent on the chosen DBMS.static final String
The property keydb.dropDb
for specifying if an existing database should be dropped when the setup is configured to create a database with the same name.static final String
The property keydb.index.tablespace
necessary dependent on the chosen DBMS.static final String
The property keydb.jdbc.driver
for specifying the fully qualified name of the Java class implementing the JDBC driver to use for the connection.static final String
The property keydb.name
for specifying the name of the database used by OpenCms, e.g.static final String
The property keydb.product
for specifying the used DBMS.static final String
The property keydb.provider
for specifying the database provider.static final String
The property keydb.template.db
necessary dependent of the chosen DBMS.static final String
The property keydb.temporary.tablespace
necessary dependent of the chosen DBMS..static final String
The property keydb.worker.pwd
for providing the password of the database user that is used when running OpenCms after the setup.static final String
The property keydb.worker.user
for providing the name of the database user that is used for the connection when running OpenCms after the setup.static final String
The property keyserver.ethernet.address
.static final String
The property keyserver.name
for specifying the server's name.static final String
The property keyserver.servlet.mapping
for specifying the name of the OpenCms servlet (by default opencms).static final String
The property keyserver.url
for specifying the server's URL.static final String
The property keysetup.default.webapp
.static final String
The property keysetup.install.components
to choose the components that should be installed during the setup.static final String
The property keysetup.show.progress
to specify if dots '.' should be printed to the real STDOUT while a setup is in progress.static final String
The property keysetup.webapp.path
to specify the path of the OpenCms webapp to install, e.g.,/var/lib/tomcat7/webapps/opencms
. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionReturns the connectionUrl.Returns the DB connection string parameters.Returns the createPwd.Returns the createUser.Returns the dbProvider.Returns the defaultTablespace.Returns the ethernetAddress.Returns the indexTablespace.Returns the installComponents.Returns the jdbcDriver.Returns the serveltMapping.Returns the serverName.Returns the serverUrl.org.opencms.configuration.CmsParameterConfiguration
Returns the setup configuration object.Returns the setupWebappName.Returns the setupWebappPath.Returns the templateDb.Returns the temporaryTablespace.Returns the webappPath.Returns the workerPwd.Returns the workerUser.boolean
Returns the createDb.boolean
Returns the createTables.boolean
isDropDb()
Returns the dropDb.boolean
Indicates if dots '.' should be printed to the real STDOUT while a setup is in progress.Converts and returns this object as map.
-
Field Details
-
LOG
The log object for this class. -
PROP_DB_CONNECTION_STRING_PARAMS
The DB connection string parameters property name.- See Also:
-
PROP_DB_CONNECTION_URL
The property keydb.connection.url
for providing the JDBC connection string, e.g.,jdbc:mysql://localhost:3306/
for the default MySQL installation.- See Also:
-
PROP_DB_CREATE_DB
The property keydb.create.db
for specifying if the database should be created during the setup.Set to
true
to create the database automatically, orfalse
if it should not.NOTE: Automatic database creation is not supported for all DBMSs.
- See Also:
-
PROP_DB_CREATE_PWD
The property keydb.create.pwd
for specifying the password for the database user that is used during the setup connection.- See Also:
-
PROP_DB_CREATE_TABLES
The property keydb.create.tables
for specifying if the database tables in the OpenCms database should be created.Set to
true
to create the database automatically, orfalse
if it should not.- See Also:
-
PROP_DB_CREATE_USER
The property keydb.create.user
for specifying the name of the database user that is used during the setup connection. NOTE: The user must have administration permissions. The user data is deleted, when the setup is finished.- See Also:
-
PROP_DB_DEFAULT_TABLESPACE
The property keydb.default.tablespace
necessary dependent on the chosen DBMS.- See Also:
-
PROP_DB_DROP_DB
The property keydb.dropDb
for specifying if an existing database should be dropped when the setup is configured to create a database with the same name. Set totrue
if existing databases should be dropped when necessary, or tofalse
if not.- See Also:
-
PROP_DB_INDEX_TABLESPACE
The property keydb.index.tablespace
necessary dependent on the chosen DBMS.- See Also:
-
PROP_DB_JDBC_DRIVER
The property keydb.jdbc.driver
for specifying the fully qualified name of the Java class implementing the JDBC driver to use for the connection.Hint: The names can be found in the
database.properties
file in the webapp' folderssetup/database/<db.product>/
.- See Also:
-
PROP_DB_NAME
The property keydb.name
for specifying the name of the database used by OpenCms, e.g. choose "opencms".- See Also:
-
PROP_DB_PRODUCT
The property keydb.product
for specifying the used DBMS. Values should match the folders under the OpenCms webapp's foldersetup/database/
.- See Also:
-
PROP_DB_PROVIDER
The property keydb.provider
for specifying the database provider.Hint: The available providers are defined as constants in
CmsSetupBean
.- See Also:
-
PROP_DB_TEMPLATE_DB
The property keydb.template.db
necessary dependent of the chosen DBMS.- See Also:
-
PROP_DB_TEMPORARY_TABLESPACE
The property keydb.temporary.tablespace
necessary dependent of the chosen DBMS..- See Also:
-
PROP_DB_WORKER_PWD
The property keydb.worker.pwd
for providing the password of the database user that is used when running OpenCms after the setup. CAUTION: For security reasons, the user should not have administration permissions. The user data is stored in theopencms.properties
file after the setup.- See Also:
-
PROP_DB_WORKER_USER
The property keydb.worker.user
for providing the name of the database user that is used for the connection when running OpenCms after the setup. CAUTION: For security reasons, the user should not have administration permissions. The user data is stored in theopencms.properties
file after the setup. .- See Also:
-
PROP_SERVER_ETHERNET_ADDRESS
The property keyserver.ethernet.address
. Specify a valid MAC-Address. It is used internally by OpenCms. (If not given, the address is generated automatically.)- See Also:
-
PROP_SERVER_NAME
The property keyserver.name
for specifying the server's name. Special server names are of particular interest in a cluster installation.- See Also:
-
PROP_SERVER_SERVLET_MAPPING
The property keyserver.servlet.mapping
for specifying the name of the OpenCms servlet (by default opencms).- See Also:
-
PROP_SERVER_URL
The property keyserver.url
for specifying the server's URL. It is used, e.g., for the site configuration.- See Also:
-
PROP_SETUP_DEFAULT_WEBAPP
The property keysetup.default.webapp
. Provide the default webapp in your servlet container (Default: ROOT).- See Also:
-
PROP_SETUP_INSTALL_COMPONENTS
The property keysetup.install.components
to choose the components that should be installed during the setup.The available components are configured in
setup/components.properties
in the webapp's folder.NOTE: You can specify the components to install also as Java system property (highest priority) or via an environment variable (second choice). The value specified in the configuration file is only the third choice.
- See Also:
-
PROP_SETUP_SHOW_PROGRESS
The property keysetup.show.progress
to specify if dots '.' should be printed to the real STDOUT while a setup is in progress.- See Also:
-
PROP_SETUP_WEBAPP_PATH
The property keysetup.webapp.path
to specify the path of the OpenCms webapp to install, e.g.,/var/lib/tomcat7/webapps/opencms
.- See Also:
-
-
Constructor Details
-
CmsAutoSetupProperties
Public constructor.- Parameters:
propertiesFile
- the path to the setup properties file- Throws:
IOException
- if the property file could not be readSecurityException
- if the environment variables could not be read
-
-
Method Details
-
getConnectionUrl
Returns the connectionUrl.- Returns:
- the connectionUrl
-
getConStrParams
Returns the DB connection string parameters.- Returns:
- the DB connection string parameters
-
getCreatePwd
Returns the createPwd.- Returns:
- the createPwd
-
getCreateUser
Returns the createUser.- Returns:
- the createUser
-
getDbName
- Returns:
- the name of the db name used
-
getDbProduct
- Returns:
- the name of the db product used
-
getDbProvider
Returns the dbProvider.- Returns:
- the dbProvider
-
getDefaultTablespace
Returns the defaultTablespace.- Returns:
- the defaultTablespace
-
getEthernetAddress
Returns the ethernetAddress.- Returns:
- the ethernetAddress
-
getIndexTablespace
Returns the indexTablespace.- Returns:
- the indexTablespace
-
getInstallComponents
Returns the installComponents.- Returns:
- the installComponents
-
getJdbcDriver
Returns the jdbcDriver.- Returns:
- the jdbcDriver
-
getServeltMapping
Returns the serveltMapping.- Returns:
- the serveltMapping
-
getServerName
Returns the serverName.- Returns:
- the serverName
-
getServerUrl
Returns the serverUrl.- Returns:
- the serverUrl
-
getSetupConfiguration
Returns the setup configuration object.- Returns:
- the setup configuration object
-
getSetupDefaultWebappName
Returns the setupWebappName.- Returns:
- the setupWebappName
-
getSetupWebappPath
Returns the setupWebappPath.- Returns:
- the setupWebappPath
-
getTemplateDb
Returns the templateDb.- Returns:
- the templateDb
-
getTemporaryTablespace
Returns the temporaryTablespace.- Returns:
- the temporaryTablespace
-
getWebappPath
Returns the webappPath.- Returns:
- the webappPath
-
getWorkerPwd
Returns the workerPwd.- Returns:
- the workerPwd
-
getWorkerUser
Returns the workerUser.- Returns:
- the workerUser
-
isCreateDb
Returns the createDb.- Returns:
- the createDb
-
isCreateTables
Returns the createTables.- Returns:
- the createTables
-
isDropDb
Returns the dropDb.- Returns:
- the dropDb
-
isShowProgress
Indicates if dots '.' should be printed to the real STDOUT while a setup is in progress.- Returns:
- true if dots '.' should be printed to the real STDOUT while a setup is in progress
-
toParameterMap
Converts and returns this object as map.- Returns:
- this object as map
-