ClickHouse/dbms/tests/queries/0_stateless/00505_tcp_ssl.sh
2017-10-03 22:12:44 +03:00

15 lines
391 B
Bash
Executable File

#!/usr/bin/env bash
# Not default server config needed
tcp_ssl_port=`clickhouse extract-from-config -c /etc/clickhouse-server/config.xml -k tcp_ssl_port 2>/dev/null`
if [ -z ${tcp_ssl_port} ]; then
# Secure port disabled. Fake result
echo 1
echo 2
else
# Auto port detect
clickhouse-client --ssl -q "SELECT 1";
clickhouse-client --ssl --port=9440 -q "SELECT 2";
fi