Skip to content

Commit 0cf8df6

Browse files
committed
Update Redpanda Console configuration to include URL schemes for endpoints
1 parent 47f76c5 commit 0cf8df6

File tree

2 files changed

+83
-46
lines changed

2 files changed

+83
-46
lines changed

modules/console/pages/config/connect-to-redpanda.adoc

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ Here is an example configuration for the Kafka API using OAuth for SASL authenti
2828
----
2929
kafka:
3030
brokers:
31-
- "broker1.example.com:9092"
32-
- "broker2.example.com:9092"
31+
- "http://broker1.example.com:9092"
32+
- "http://broker2.example.com:9092"
3333
# Optional client identification:
3434
# clientId: "console"
3535
# rackId: "zone-a"
@@ -67,7 +67,7 @@ For clusters using Kerberos, the configuration may resemble the following:
6767
----
6868
kafka:
6969
brokers:
70-
- "broker1.example.com:9092"
70+
- "http://broker1.example.com:9092"
7171
sasl:
7272
enabled: true
7373
mechanism: GSSAPI
@@ -90,7 +90,7 @@ NOTE: Because Redpanda Console supports only OIDC and basic authentication for i
9090
| Kafka API Configuration Option | Description
9191

9292
| `brokers`
93-
| A list of broker endpoints in the format `<hostname>:<port>`. For high availability, include all broker URLs.
93+
| A list of Kafka broker endpoints including the URL scheme (`http://` or `https://`), hostname, and port. Include all brokers in your cluster for high availability.
9494

9595
| `clientId` (optional)
9696
| An identifier used by Redpanda Console to identify itself to the cluster.
@@ -137,8 +137,8 @@ Example Schema Registry configuration:
137137
schemaRegistry:
138138
enabled: true
139139
urls:
140-
- "broker1.example.com:8081"
141-
- "broker2.example.com:8081"
140+
- "http://broker1.example.com:8081"
141+
- "http://broker2.example.com:8081"
142142
143143
# Optional authentication settings
144144
authentication:
@@ -154,7 +154,7 @@ schemaRegistry:
154154
| Schema Registry Configuration Option | Description
155155

156156
| `urls`
157-
| A list of Schema Registry endpoints in the format `<hostname>:<port>`. Include all endpoints for redundancy.
157+
| A list of Schema Registry endpoints including the URL scheme (`http://` or `https://`), hostname, and port. Include all endpoints for redundancy.
158158

159159
| `authentication` (optional)
160160
| Configure authentication for the Schema Registry. Options include basic authentication or bearer tokens. For more detailed instructions on configuring authentication, see xref:console:config/security/authentication.adoc[].
@@ -173,8 +173,8 @@ redpanda:
173173
adminApi:
174174
enabled: true # Enable connection to the Admin API.
175175
urls:
176-
- "broker1.example.com:9644" # Provide all endpoints (host:port) for high availability.
177-
- "broker2.example.com:9644"
176+
- "http://broker1.example.com:9644" # Provide all endpoints (host:port) for high availability.
177+
- "http://broker2.example.com:9644"
178178
# Optional authentication settings
179179
authentication:
180180
impersonateUser: true # Use the logged-in user's credentials for authentication.
@@ -202,7 +202,7 @@ NOTE: Include the URLs of _all_ endpoints in the `redpanda.adminApi.urls` array.
202202
| Activates the connection to the Admin API. Set to `true` to enable the integration.
203203

204204
| `urls`
205-
| A list of endpoints (host:port) for all brokers serving the Admin API. Providing all URLs enhances reliability.
205+
| A list of Admin API endpoints including the URL scheme (`http://` or `https://`), hostname, and port. Providing all URLs enhances reliability.
206206

207207
| `authentication` (optional)
208208
| Provides credentials using basic authentication or bearer tokens when impersonation is disabled. For more detailed instructions on configuring authentication, see xref:console:config/security/authentication.adoc[].

modules/manage/pages/security/listener-configuration.adoc

Lines changed: 73 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -4,101 +4,138 @@
44
:page-aliases: cluster-administration:listener-configuration.adoc
55
:page-categories: Management, Security
66

7+
Apache Kafka® client libraries must be able to connect to every Redpanda broker instance. If the client and broker are on different subnets, advertise the location of the broker in the Redpanda configuration file so other brokers in the cluster can be found. If not, clients connecting to brokers outside their local network experience connectivity issues.
78

8-
Apache Kafka® client libraries must be able to connect to every Redpanda broker
9-
instance. If the client and broker are on different subnets, advertise the location of the broker in the Redpanda configuration file so other brokers in
10-
the cluster can be found. If not, clients connecting to brokers outside
11-
their local network experience connectivity issues.
12-
13-
To try out Redpanda, see the
14-
xref:get-started:quick-start.adoc[Redpanda Quickstart].
9+
To try out Redpanda, see the xref:get-started:quick-start.adoc[Redpanda quickstart].
1510

1611
== Anatomy of a listener
1712

18-
Clients must connect to Redpanda with a TCP socket. A TCP socket is described by an IP address of an interface and a port on the machine that Redpanda runs on. For example:
13+
Clients connect to Redpanda over TCP. A listener is defined by an interface address and port on the machine running Redpanda. For example:
14+
15+
[cols="1,1"]
16+
|===
17+
|Configuration | Description
18+
19+
|`address: 0.0.0.0`
20+
|Listens on all available interfaces.
21+
22+
|`port: 9092`
23+
|TCP port for Kafka clients.
24+
25+
|===
1926

20-
[,yaml]
27+
[source,yaml]
2128
----
2229
redpanda:
2330
kafka_api:
2431
- address: 0.0.0.0
2532
port: 9092
2633
----
2734

28-
An address of `0.0.0.0` means that Redpanda listens on all interfaces.
29-
3035
== Advertise a listener
3136

32-
By default, the advertised address is the address the listener is bound to, but this is not usually an externally-routable address. Set the advertised address to an address the client can use to connect to the instance of Redpanda.
33-
34-
NOTE: Ensure that any configuration option with the `advertise_*` prefix uses a valid hostname or IP address. Do not use `0.0.0.0`. Invalid configurations, including the use of `0.0.0.0`, will cause the broker to fail during startup validation.
37+
By default, the advertised address is the same as the bound address. For clients outside the local host or subnet, you must set an externally reachable address or hostname. Invalid settings—including `0.0.0.0`—will fail startup validation.
3538

36-
If the client exists on another subnet, then it needs to know how to reach Redpanda. Do this by configuring the advertised address of the Kafka API in `redpanda.yaml`. For example, if Redpanda is running on the subnet `192.168.4.0/24` with IP address `192.168.4.1`, and the clients are running on the subnet `192.168.5.0/24`, then the client machine needs a gateway configured to route requests to `192.168.4.1`:
37-
38-
[,yaml]
39+
[source,yaml]
3940
----
4041
redpanda:
4142
advertised_kafka_api:
42-
- address: 192.168.4.1
43+
- address: 192.168.4.1 # Broker’s routable IP or FQDN
4344
port: 9092
4445
----
4546

46-
It's also possible to advertise a host name, provided the client can resolve the DNS and has a route to the host.
47+
[NOTE]
48+
====
49+
* Use a valid hostname or IP. Do not use `0.0.0.0`.
50+
* When using a DNS hostname, ensure clients can resolve it and that it matches any TLS certificate SAN.
51+
====
4752

4853
== Multiple listeners
4954

50-
Sometimes it's useful to have multiple configurations for accessing Redpanda with multiple routes.
51-
52-
Do this by creating multiple listeners, and providing a name for the listener. The name is used to connect the listener and its advertised address. For example:
55+
You can define multiple Kafka API listeners to support different interfaces, ports, or authentication methods. Each listener must have a unique `name` property, and the same `name` property must be used in the corresponding `advertised_kafka_api` stanza.
5356

54-
[,yaml]
57+
[source,yaml]
5558
----
5659
redpanda:
5760
kafka_api:
58-
- name: local
61+
- name: local # Unique listener name
5962
address: 127.0.0.1
6063
port: 9092
64+
6165
- name: subnet
6266
address: 192.168.4.1
6367
port: 9093
68+
6469
advertised_kafka_api:
65-
- name: local
70+
- name: local # Must match the listener name
6671
address: 127.0.0.1
6772
port: 9092
73+
6874
- name: subnet
6975
address: 192.168.4.1
7076
port: 9093
7177
----
7278

73-
You can also create additional listeners for different configurations of TLS or authentication.
79+
== TLS listeners and DNS hostnames
80+
81+
For encrypted connections, you typically advertise a DNS name matching your TLS certificate. Always include a `name` property for the TLS listener and use it in both `kafka_api` and `advertised_kafka_api`.
82+
83+
[source,yaml]
84+
----
85+
redpanda:
86+
kafka_api:
87+
- name: tls_listener
88+
address: 0.0.0.0
89+
port: 9094
90+
authentication_method: mtls_identity
91+
92+
advertised_kafka_api:
93+
- name: tls_listener
94+
address: https://kafka.example.com
95+
port: 9094
96+
97+
kafka_api_tls:
98+
- name: tls_listener
99+
enabled: true
100+
key_file: /etc/redpanda/tls/broker.key
101+
cert_file: /etc/redpanda/tls/broker.crt
102+
truststore_file: /etc/redpanda/tls/ca.crt
103+
require_client_auth: true
104+
----
105+
106+
Ensure `kafka.example.com` matches the SAN in `broker.crt` and that clients trust the `ca.crt`.
74107

75108
== Mixed-mode authentication with multiple listeners
76109

77-
Redpanda supports using both SASL and mTLS principal extraction authentication methods using multiple listeners. This supports a variety of Kafka clients using various authentication schemes all connecting to your cluster. For example:
110+
Redpanda supports running multiple authentication schemes side by side. Each listener can specify its method, and must define a `name:`.
78111

79-
[,yaml]
112+
[source,yaml]
80113
----
81114
redpanda:
82115
kafka_api:
83-
- address: 0.0.0.0
116+
- name: sasl_listener
117+
address: 0.0.0.0
84118
port: 9092
85-
name: sasl_listener
86119
authentication_method: sasl
87-
- address: 0.0.0.0
120+
121+
- name: mtls_listener
122+
address: 0.0.0.0
88123
port: 9192
89-
name: mtls_listener
90124
authentication_method: mtls_identity
125+
91126
kafka_api_tls:
92127
- name: mtls_listener
93128
key_file: mtls_broker.key
94129
cert_file: mtls_broker.crt
95130
truststore_file: mtls_ca.crt
96-
enabled: true
97131
require_client_auth: true
98132
----
99133

100134
== Listeners that can be advertised
101135

102-
* `kafka_api` \-> `advertised_kafka_api`: The address that Kafka clients connect to, for each listener.
103-
* `rpc_server` \-> `advertised_rpc_api`: The address that other Redpanda instances connect to.
104-
* `pandaproxy_api` \-> `advertised_pandaproxy_api`: The address that HTTP clients connect to, for each listener.
136+
* `kafka_api` → `advertised_kafka_api`: Kafka clients connect here.
137+
* `rpc_server` → `advertised_rpc_api`: Other Redpanda brokers connect here.
138+
* `pandaproxy_api` → `advertised_pandaproxy_api`: HTTP clients connect here.
139+
140+
For each advertised block, match the `name:` of the corresponding listener and provide a valid address and port.
141+

0 commit comments

Comments
 (0)