Skip to content

Commit fb17651

Browse files
authored
Add client to proxy TLS support (--proxy-cert-file and --proxy-key-file) (#97)
1 parent eb8d2d3 commit fb17651

File tree

12 files changed

+479
-344
lines changed

12 files changed

+479
-344
lines changed

README.md

Lines changed: 19 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -39,30 +39,38 @@ Usage: cql-proxy
3939

4040
Flags:
4141
-h, --help Show context-sensitive help.
42-
-b, --astra-bundle=STRING Path to secure connect bundle for an Astra database. Requires '--username' and '--password'. Ignored if using the token or contact points
43-
option ($ASTRA_BUNDLE).
44-
-t, --astra-token=STRING Token used to authenticate to an Astra database. Requires '--astra-database-id'. Ignored if using the bundle path or contact points option
45-
($ASTRA_TOKEN).
42+
-b, --astra-bundle=STRING Path to secure connect bundle for an Astra database. Requires '--username' and '--password'. Ignored if using the
43+
token or contact points option ($ASTRA_BUNDLE).
44+
-t, --astra-token=STRING Token used to authenticate to an Astra database. Requires '--astra-database-id'. Ignored if using the bundle path
45+
or contact points option ($ASTRA_TOKEN).
4646
-i, --astra-database-id=STRING Database ID of the Astra database. Requires '--astra-token' ($ASTRA_DATABASE_ID)
4747
--astra-api-url="https://api.astra.datastax.com" URL for the Astra API ($ASTRA_API_URL)
4848
-c, --contact-points=CONTACT-POINTS,... Contact points for cluster. Ignored if using the bundle path or token option ($CONTACT_POINTS).
4949
-u, --username=STRING Username to use for authentication ($USERNAME)
5050
-p, --password=STRING Password to use for authentication ($PASSWORD)
5151
-r, --port=9042 Default port to use when connecting to cluster ($PORT)
52-
-n, --protocol-version="v4" Initial protocol version to use when connecting to the backend cluster (default: v4, options: v3, v4, v5, DSEv1, DSEv2) ($PROTOCOL_VERSION)
53-
-m, --max-protocol-version="v4" Max protocol version supported by the backend cluster (default: v4, options: v3, v4, v5, DSEv1, DSEv2) ($MAX_PROTOCOL_VERSION)
52+
-n, --protocol-version="v4" Initial protocol version to use when connecting to the backend cluster (default: v4, options: v3, v4, v5, DSEv1,
53+
DSEv2) ($PROTOCOL_VERSION)
54+
-m, --max-protocol-version="v4" Max protocol version supported by the backend cluster (default: v4, options: v3, v4, v5, DSEv1, DSEv2)
55+
($MAX_PROTOCOL_VERSION)
5456
-a, --bind=":9042" Address to use to bind server ($BIND)
5557
-f, --config=CONFIG YAML configuration file ($CONFIG_FILE)
5658
--debug Show debug logging ($DEBUG)
5759
--health-check Enable liveness and readiness checks ($HEALTH_CHECK)
5860
--http-bind=":8000" Address to use to bind HTTP server used for health checks ($HTTP_BIND)
5961
--heartbeat-interval=30s Interval between performing heartbeats to the cluster ($HEARTBEAT_INTERVAL)
60-
--idle-timeout=60s Duration between successful heartbeats before a connection to the cluster is considered unresponsive and closed ($IDLE_TIMEOUT)
61-
--readiness-timeout=30s Duration the proxy is unable to connect to the backend cluster before it is considered not ready ($READINESS_TIMEOUT)
62-
--idempotent-graph If true it will treat all graph queries as idempotent by default and retry them automatically. It may be dangerous to retry some graph
63-
queries -- use with caution ($IDEMPOTENT_GRAPH).
62+
--idle-timeout=60s Duration between successful heartbeats before a connection to the cluster is considered unresponsive and closed
63+
($IDLE_TIMEOUT)
64+
--readiness-timeout=30s Duration the proxy is unable to connect to the backend cluster before it is considered not ready
65+
($READINESS_TIMEOUT)
66+
--idempotent-graph If true it will treat all graph queries as idempotent by default and retry them automatically. It may be
67+
dangerous to retry some graph queries -- use with caution ($IDEMPOTENT_GRAPH).
6468
--num-conns=1 Number of connection to create to each node of the backend cluster ($NUM_CONNS)
65-
--rpc-address=STRING Address to advertise in the 'system.local' table for 'rpc_address'. It must be set if configuring peer proxies ($RPC_ADDRESS)
69+
--proxy-cert-file=STRING Path to a PEM encoded certificate file with its intermediate certificate chain. This is used to encrypt traffic
70+
for proxy clients ($PROXY_CERT_FILE)
71+
--proxy-key-file=STRING Path to a PEM encoded private key file. This is used to encrypt traffic for proxy clients ($PROXY_KEY_FILE)
72+
--rpc-address=STRING Address to advertise in the 'system.local' table for 'rpc_address'. It must be set if configuring peer proxies
73+
($RPC_ADDRESS)
6674
--data-center=STRING Data center to use in system tables ($DATA_CENTER)
6775
--tokens=TOKENS,... Tokens to use in the system tables. It's not recommended ($TOKENS)
6876
```

0 commit comments

Comments
 (0)