> For the complete documentation index, see [llms.txt](https://newdocs.keeper.io/kcm-linux-rpm-method/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://newdocs.keeper.io/kcm-linux-rpm-method/vault-integration/advanced.md).

# Advanced

<figure><img src="/files/EtIWih8bIhqt76kTTgij" alt=""><figcaption></figcaption></figure>

## Config Parameter Protection

The Keeper Vault can be utilized to protect and store configuration secrets that would normally be hard-coded into the `guacamole.properties` or Docker Compose file.

### **Auto Docker Install Method**

If you installed Keeper Connection Manager using the Auto Docker Install method, configuration secrets are protected in the auto-generated Docker Compose file.

As root, edit the `/etc/kcm-setup/docker-compose.yml` file.

For each configuration secret that you want to protect, you can replace the entry with a direct lookup in the Keeper vault. A good example of this is replacing the hard-coded MySQL database password with a vault record.

**BEFORE:**

```
MYSQL_HOSTNAME: "db"
MYSQL_DATABASE: "guacamole_db"
MYSQL_USERNAME: "guacamole_user"
MYSQL_PASSWORD: "your_mysql_database_password"
```

**AFTER:**

```
MYSQL_HOSTNAME: "db"
MYSQL_DATABASE: "guacamole_db"
MYSQL_USERNAME: "guacamole_user"
MYSQL_PASSWORD_KSM_SECRET: keeper://2ZlOFQAYi4DubJWBtSbRxw/field/password
```

The token syntax is using [Keeper Notation](https://docs.keeper.io/secrets-manager/secrets-manager/about/keeper-notation). The name of the parameter must follow the format of `*_KSM_SECRET`. In this example, the MySQL database password is pulled directly from a Keeper record in the Shared Folder.

![Configuration Storage in the Keeper Vault](/files/3DXNZ4eQhKik78gwEsId)

The value of each `*_KSM_SECRET` variable should be the Keeper notation of the secret that should be used to pull the necessary configuration value. For example, if `SOME_VARIABLE_KSM_SECRET` were set to valid Keeper notation, then the value of the Guacamole property normally associated with `SOME_VARIABLE` will be pulled from that secret in KSM.

Once the file changes have been saved, update the containers:

```
$ sudo ./kcm-setup.run upgrade
```

### **Docker Compose Install Method**

Edit your `docker-compose.yml` file.

For each configuration secret that you want to protect, you can replace the entry with a direct lookup in the Keeper vault. A good example of this is replacing the hard-coded MySQL database password with a vault record:

```
MYSQL_HOSTNAME: "db"
MYSQL_DATABASE: "guacamole_db"
MYSQL_USERNAME: "guacamole_user"
MYSQL_PASSWORD_KSM_SECRET: keeper://2ZlOFQAYi4DubJWBtSbRxw/field/password
```

The token syntax is using [Keeper Notation](https://docs.keeper.io/secrets-manager/secrets-manager/about/keeper-notation). In this example, the MySQL database password is pulled directly from a Keeper record in the Shared Folder as seen below:

![Configuration Storage in the Keeper Vault](/files/3DXNZ4eQhKik78gwEsId)

The value of each `*_KSM_SECRET` variable should be the Keeper notation of the secret that should be used to pull the necessary configuration value. For example, if `SOME_VARIABLE_KSM_SECRET` were set to valid Keeper notation, then the value of the Guacamole property normally associated with `SOME_VARIABLE` will be pulled from that secret in KSM.

Once the file changes have been saved, update the containers:

```
sudo su
docker-compose up -d
```

### **Advanced Linux Install Method**

To utilize Keeper Vault storage of Guacamole properties, create a file `guacamole.properties.ksm` in the same location as your `guacamole.properties` file (`/etc/guacamole/` by default).

In the new file, add any properties that you would like to store in the Keeper vault, and set the value to a [Keeper Notation](https://docs.keeper.io/secrets-manager/secrets-manager/about/keeper-notation) query of the record field to use for that property. Note that the `guacamole.properties` file must still contain the `ksm-config` property to identify the Keeper Secrets Manager configuration.

**Example Setup**

guacamole.properties:

{% code title="" %}

```
ksm-config: eyJob3N0bm[...]1IzRTN2UVNTNkhsb0NZQW9nUmlPVlY5cjhvUT0ifQ==
```

{% endcode %}

guacamole.properties.ksm:

```
mysql-hostname: keeper://tqd1F9zHRKokN44Xso8PkQ/field/host[hostname]
mysql-port: keeper://tqd1F9zHRKokN44Xso8PkQ/field/host[port]
mysql-password: keeper://tqd1F9zHRKokN44Xso8PkQ/field/password
```

The token syntax is using [Keeper Notation](https://docs.keeper.io/secrets-manager/secrets-manager/about/keeper-notation). In this example, the MySQL database password is pulled directly from a Keeper record with the specified UID `tqd1F9zHRKokN44Xso8PkQ.`

Then, restart the guacamole process as you typically would.

```
$ sudo systemctl restart guacamole
```

{% hint style="info" %}
The records referenced by token replacement must be in a shared folder that your Secrets Manager Application has access to.
{% endhint %}

### Other configuration options

In docker installations, the parameter `ADDITIONAL_GUACAMOLE_PROPERTIES_KSM` can be used to move parameters from the guacamole.properties file into guacamole.properties.ksm.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://newdocs.keeper.io/kcm-linux-rpm-method/vault-integration/advanced.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
