# Proxy Configuration to Access Hosts

## Problem

* Configure host to connect to Platform9 Cloud (Management Plane) via proxy server instead of direct connectivity.

## Environment

* Platform9 Managed OpenStack - All Versions
* Platform9 Managed Kubernetes - All Versions

## Procedure

1. First test host side connectivity via proxy by referring to [Test Host Connectivity to the Management Plane via Proxy.](https://platform9.com/kb/platform9/test-host-connectivity-to-the-management-plane-via-proxy)
2. Once connectivity is successfully tested, create file */etc/pf9/comms\_proxy\_cfg.json* in the following format and substitute the respective values.

{% tabs %}
{% tab title="None" %}

```none
{
        "http_proxy": {
            "protocol": "[http|https]",
            "host": "[PROXY FQDN/IP]",
            "port": [PROXY PORT],
            "user": "[PROXY USERNAME]",
            "pass": "[PROXY PASSWORD]"
        }
    }
```

{% endtab %}
{% endtabs %}

**Note:** If username has backward slash(`\`) characters then escape each one of them with an additional backward slash like `\\`

3. Restart the ***pf9-comms*** and ***pf9-sidekick*** services.

{% tabs %}
{% tab title="None" %}

```none
service pf9-comms restart
service pf9-sidekick restart
```

{% endtab %}
{% endtabs %}

4. Tail comms log ( */var/log/pf9/comms/comms.log)* for errors.
5. Run the command below and verify connectivity.

{% tabs %}
{% tab title="None" %}

```none
curl http://localhost:8158/keystone
```

{% endtab %}
{% endtabs %}


---

# Agent Instructions: 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:

```
GET https://platform9.com/kb/generic/how-to/proxy-configuration-to-access-hosts.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
