fix(http): force enable ssl when https
This commit is contained in:
parent
fa85c3061b
commit
a6357d92f8
|
@ -205,7 +205,9 @@ on_start(
|
|||
http ->
|
||||
{tcp, []};
|
||||
https ->
|
||||
SSLOpts = emqx_tls_lib:to_client_opts(maps:get(ssl, Config)),
|
||||
SSLConf = maps:get(ssl, Config),
|
||||
%% force enable ssl
|
||||
SSLOpts = emqx_tls_lib:to_client_opts(SSLConf#{enable => true}),
|
||||
{tls, SSLOpts}
|
||||
end,
|
||||
NTransportOpts = emqx_utils:ipv6_probe(TransportOpts),
|
||||
|
|
|
@ -150,7 +150,8 @@ tr_handler_conf(#{logs := LogsConf, exporter := ExporterConf}) ->
|
|||
ssl_opts(Endpoint, SSLOpts) ->
|
||||
case is_ssl(Endpoint) of
|
||||
true ->
|
||||
emqx_tls_lib:to_client_opts(SSLOpts);
|
||||
%% force enable ssl
|
||||
emqx_tls_lib:to_client_opts(SSLOpts#{enable => true});
|
||||
false ->
|
||||
[]
|
||||
end.
|
||||
|
|
Loading…
Reference in New Issue