Skip to content

Commit

Permalink
Merge pull request #11813 from qzhuyan/fix/william/genrpc-ssl-port-align
Browse files Browse the repository at this point in the history
Fix/william/genrpc ssl port align
  • Loading branch information
qzhuyan committed Oct 25, 2023
2 parents 33db5f5 + 6346e0d commit 37dd44c
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/workflows/run_helm_tests.yaml
Expand Up @@ -89,6 +89,7 @@ jobs:
EMQX_RPC__CACERTFILE: /opt/emqx/etc/certs/cacert.pem
EMQX_RPC__CIPHERS: TLS_AES_256_GCM_SHA384,TLS_AES_128_GCM_SHA256
EMQX_RPC__TLS_VERSIONS: "[tlsv1.2]"
EMQX_RPC__PORT_DISCOVERY: manual
EOL
- name: run emqx on chart (k8s)
if: matrix.discovery == 'k8s'
Expand Down
4 changes: 4 additions & 0 deletions apps/emqx_conf/src/emqx_conf_schema.erl
Expand Up @@ -1151,6 +1151,7 @@ translation("emqx") ->
translation("gen_rpc") ->
[
{"default_client_driver", fun tr_gen_rpc_default_client_driver/1},
{"ssl_client_port", fun tr_gen_rpc_ssl_client_port/1},
{"ssl_client_options", fun tr_gen_rpc_ssl_options/1},
{"ssl_server_options", fun tr_gen_rpc_ssl_options/1},
{"socket_ip", fun(Conf) ->
Expand Down Expand Up @@ -1226,6 +1227,9 @@ collector_enabled(disabled, _) -> [].
tr_gen_rpc_default_client_driver(Conf) ->
conf_get("rpc.protocol", Conf).

tr_gen_rpc_ssl_client_port(Conf) ->
conf_get("rpc.ssl_server_port", Conf).

tr_gen_rpc_ssl_options(Conf) ->
Ciphers = conf_get("rpc.ciphers", Conf),
Versions = conf_get("rpc.tls_versions", Conf),
Expand Down
4 changes: 4 additions & 0 deletions changes/ce/fix-11813.en.md
@@ -0,0 +1,4 @@
Fix schema: RPC client ssl port alighn with configured server port.
And ensure RPC ports are opened in helm chart.


4 changes: 4 additions & 0 deletions deploy/charts/emqx-enterprise/templates/StatefulSet.yaml
Expand Up @@ -121,6 +121,10 @@ spec:
{{- end }}
- name: ekka
containerPort: 4370
- name: genrpc-manual
containerPort: 5369
- name: genrpc2-auto
containerPort: 5370
envFrom:
- configMapRef:
name: {{ include "emqx.fullname" . }}-env
Expand Down
4 changes: 4 additions & 0 deletions deploy/charts/emqx/templates/StatefulSet.yaml
Expand Up @@ -121,6 +121,10 @@ spec:
{{- end }}
- name: ekka
containerPort: 4370
- name: genrpc-manual
containerPort: 5369
- name: genrpc2-auto
containerPort: 5370
envFrom:
- configMapRef:
name: {{ include "emqx.fullname" . }}-env
Expand Down

0 comments on commit 37dd44c

Please sign in to comment.