Administrate the DPF Configuration¶
In an on-premise installation, the configuration of Digital Process Factory is kept in the Consul key value store and can be administrated by DPF CLI. In a cloud environment, the container orchestration system is used for this.
Requirements¶
For the requirements for using DPF CLI, refer to DPF CLI.
Commands and Options¶
Usage: dpf config [options] [command]
Options:
-V, --version output the version number
--consul <value> consul url (https://localhost:8500) (default: "https://localhost:8500")
--insecure accept invalid https certificate from Consul server
--token <value> ACL token used to access Consul's key-/value store
-h, --help display help for command
Commands:
import [options] <configfile> import new configuration
required arguments:
configfile: the path and name of the configuration file in YAML format
update [options] <configfile> update configuration, don't overwrite existing entries
required arguments:
configfile: the path and name of the configuration file in YAML format
export [options] <configfile> export new configuration
required arguments:
configfile: the path and name of the target configuration file
set [options] <key> [<value>] set configuration parameter
required arguments:
key: the name of the configuration parameter
value: the value for the configuration parameter (not required if option --file is specified)
get [options] <key> get configuration parameter
required arguments:
key: the name of the configuration parameter
help [command] display help for command
Hint - self-signed certificate
If DPF CLI returns "DEPTH_ZERO_SELF_SIGNED_CERT", add the --insecure option to your command.
help¶
help displays the help for the command.
Usage: dpf config help [command]
export¶
export exports the current configuration as stored in Consul as YAML file.
Usage: dpf config export [options] <configfile>
Arguments:
configfile: path and name of the target configuration file, mandatory
Options:
--dc <value>: name of the source datacenter to export configuration (default:home)
Examples:
-
dpf config export export.ymlExports the configuration and save it to the file
export.ymlin the current directory. -
dpf config export export.yml --insecureExports the configuration and save it to the file
export.ymlin the current directory. The certificate will not be checked by the client. -
dpf config export <filename>.yml --token <consul_token>Export the configuration from a secured Consul key value store.
get¶
get returns the value of a configuration parameter. If the parameter is not set, the command returns Failed to get configuration parameter.
Usage: dpf config get [options] <key>
Arguments:
key: name of the configuration parameter, mandatory. For the list of available keys, refer to Keys.
Options:
--file <value>: path and name of the file to write the value into--service <value>: name of the service withoutseal-for which to get the configuration value (default:any)--dc <value>: name of the target datacenter from which to get the configuration value. (default:home)
Examples:
-
dpf config get LOG_LEVELReturns the value set for the
LOG_LEVELkey if set for any service. -
dpf config get LOG_LEVEL --insecureReturns the value set for the
LOG_LEVELkey if set for any service. The certificate will not be checked by the client. -
dpf config get DPFROOT --service dpf-jobcleaner --insecureReturns the value set for the
DPFROOTkey if set forseal-dpf-jobcleanerservice. The certificate will not be checked by the client. -
dpf config get LOG_LEVEL --insecure --file C:\temp\loglevel.txtReturns the value set for the
LOG_LEVELkey if set for any service. The output is saved asloglevel.txtin the current directory. The certificate will not be checked by the client.
import¶
import imports the configuration from a YAML file into Consul.
Usage: dpf config import [options] <configfile>
Arguments:
configfile: path and name of the target configuration file, mandatory
Options:
--purge: deletes the current configuration before import--dc <value>: name of the source datacenter to export configuration (default:home)
Examples:
-
dpf config import config.ymlReads the configuration from
config.ymlin the current directory and updates the configuration in Consul. Existent values will be overwritten. -
dpf config import config.yml --insecureReads the configuration from
config.ymlin the current directory and updates the configuration in Consul. Existent values will be overwritten. The certificate will not be checked by the client. -
dpf config import config.yml --token <consul_token>
Reads the configuration from config.yml in the current directory and updates the configuration in a secured Consul. Existent values will be overwritten.
dpf config import config.yml --purge --insecure
Deletes the current configuration. Reads the configuration from config.yml in the current directory and imports it into Consul.
set¶
set sets the value of a configuration parameter.
Usage: dpf config set [options] <key> [<value>]
Arguments:
key: name of the configuration parameter, mandatory. For the list of available keys, refer to Keys.value: the value for the configuration parameter (not required if option--fileis specified)
Options:
--json: activate json syntax check--file <value>: file to read the value from--service <value>: name of the service withoutseal-for which to set the configuration value (default:any)--dc <value>: name of the target datacenter in which to set the configuration value. (default:home)
Examples:
-
dpf config set LOG_LEVEL warnSets the value
warnfor theLOG_LEVELkey for any service. -
dpf config set LOG_LEVEL warn --insecureSets the value
warnfor theLOG_LEVELkey for any service. The certificate will not be checked by the client. -
dpf config set LOG_LEVEL warn --service dpf-jobcleaner --insecureSets the value
warnfor theLOG_LEVELkey forseal-dpf-jobcleanerservice. The certificate will not be checked by the client.
Hint - delete a key
DPF CLI has no command for deleting a key. Delete it in the user interface of Consul. In the key list, open the ... menu of the key in the Actions column and select Delete.
Other SEAL products that use the same Consul also store their configuration below dc/home/env/service/, for example PLOSSYS Output Engine. dc/home/env/service/any contains the default values for all services regardless of the SEAL product.
update¶
update updates the current configuration with a new configuration while keeping the old configuration values and only adding new entries.
Usage: dpf config update [options] <configfile>
Arguments:
configfile: the path and name of the configuration file in YAML format, mandatory
Options:
--dc <value>: name of the target datacenter to update configuration. (default: home)
Examples:
-
dpf config update config.ymlReads the configuration from
config.ymlin the current directory and updates the configuration in Consul. Existent values will be not be overwritten. -
dpf config update config.yml --insecureReads the configuration from
config.ymlin the current directory and updates the configuration in Consul. Existent values will be not be overwritten. The certificate will not be checked by the client. -
dpf config update config.yml --token <consul_token>Reads the configuration from
config.ymlin the current directory and updates the configuration in a secured Consul. Existent values will be not be overwritten.