> ## Documentation Index
> Fetch the complete documentation index at: https://docs.flexagon.com/llms.txt
> Use this file to discover all available pages before exploring further.

# FlexDeploy HTTPS Agent - Additional Configuration

> Properties Override File Properties sent from FlexDeploy can be overridden by adding a FlexDeployPropertiesOverride.properties override file to the &l

## Properties Override File

Properties sent from FlexDeploy can be overridden by adding a FlexDeployPropertiesOverride.properties override file to the \<Agent home>/config folder. There is an example file included with the installation.

> [!NOTE]
>
> The values in a properties file will be encrypted.

The purpose of this file is to not have to store the passwords in FlexDeploy and have them passed over HTTPS. They are only locally on this endpoint.

This properties file uses Java properties file syntax. The key is the code for a Target a dot and then the name of the property. The value is the value that the property should be. See this example:

```
EBS.FDEBS_DB_PASSWORD=databasepassword
```

Now the EBS password for the EBS Target will be overridden.

This file is read in during each plugin execution, so no restart of the agent is required when updating the file.

An encrypted value will look something like this:

```
EBS.FDEBS_DB_PASSWORD=#ENC#aeworuowpitydhnca
```

To change the value, simply overwrite the encrypted value. The next time a plugin is executed on the endpoint or after a small period of time it will be encrypted automatically.

## setenvoverride File

If a setenvoverride.sh (or setenvoverride.bat) file is included in the \<Agent home>/config folder, it will be run before tomcat is started in order to configure some environment variables. The following variables are supported.

<table><colgroup><col /><col /></colgroup><tbody><tr><th>**Variable**</th><th>**Description**</th></tr><tr><td>`JAVA_HOME`</td><td>The Java path where Tomcat will be run from. This is distinct from the Java path used in the endpoint configuration. The agent will attempt to derive this value from the system path, but sometimes that doesn’t work correctly. You can set it here to override that.</td></tr><tr><td>`FD_MAX_MEMORY_SIZE`</td><td>This will set the maximum memory size for the Tomcat server. Will be forwarded as the -Xmx java argument. If none is set defaults to 2048m.</td></tr><tr><td>`FD_INITIAL_MEMORY_SIZE`</td><td>This will be set the initial memory size for the Tomcat server. Will be forwarded as the -Xms java argument. If none is set defaults to 512m.</td></tr><tr><td>`FLEXAGON_FD_JAVA_ARGS`</td><td>Any extra Java arguments.</td></tr><tr><td>`FD_AGENT_PROPERTIES_PASSWORD`</td><td>This property is used to encrypt the properties file. However it is not recommended you set this environment variable here as it will be available in plaintext then.</td></tr></tbody></table>

### Examples

#### Linux

```
JAVA_HOME=/u01/java/jdk1.8.0_361
FD_MAX_MEMORY_SIZE=4096m
FD_INITIAL_MEMORY_SIZE=1024m
FLEXAGON_FD_JAVA_ARGS=-Dthis.is.an.argument=test
```

#### Windows

```
set JAVA_HOME=C:\\installs\\jdk1.8.0_212
set FD_MAX_MEMORY_SIZE=4096m
set FD_INITIAL_MEMORY_SIZE=1024m
set FLEXAGON_FD_JAVA_ARGS=-Dthis.is.an.argument=test
```

## Certificate expiration warnings

*@Since 11.2.0.0* The agent warns in agent logs (daily) and plugin execution logs when the Tomcat SSL certificate has expired or will expire within the warning window. Optional Java system properties can be set with `FLEXAGON_FD_JAVA_ARGS` in setenvoverride. Restart the agent after changing them.

<table><colgroup><col /><col /></colgroup><tbody><tr><th>**System property**</th><th>**Description**</th></tr><tr><td>`flexagon.fd.https.agent.cert.warn.days`</td><td>Days before expiry to start warning. Default is 30.</td></tr><tr><td>`flexagon.fd.https.agent.keystore.file`</td><td>Override path to the keystore. If unset, the agent uses `keystoreFile` from server.xml, or config/tomcat.jks.</td></tr><tr><td>`flexagon.fd.https.agent.keystore.password`</td><td>Override keystore password. If unset, the agent uses `keystorePass` from server.xml.</td></tr><tr><td>`flexagon.fd.https.agent.keystore.alias`</td><td>Certificate alias to check. Default is tomcat.</td></tr></tbody></table>

Example:

```
FLEXAGON_FD_JAVA_ARGS=-Dflexagon.fd.https.agent.cert.warn.days=45
```
