ClickHouse/tests/queries/0_stateless/02301_harmful_reexec.sh
Azat Khuzhin 40f3dbb448 Ignore harmful env variables in clickhouse binaries (reexec w/o them)
Some environments may really require LD_LIBRARY_PATH (and some other
variables), so rejecting running clickhouse binaries in such envs is a
backward incompatible change.

So instead of rejecting, let's ignore those env variables, i.e. reexec
binaries without them.

Also note, that there is no messages in stderr in case of some of
variables set anymore, since this message may break some scripts.

Refs: #36340
Follow-up for: #36342
2022-05-14 12:08:48 +03:00

10 lines
316 B
Bash
Executable File

#!/usr/bin/env bash
CUR_DIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
# shellcheck source=../shell_config.sh
. "$CUR_DIR"/../shell_config.sh
# NOTE: we can do a better test with strace, but I don't think that it is worth it.
$CLICKHOUSE_LOCAL -q "SELECT 1"
LD_LIBRARY_PATH=/tmp $CLICKHOUSE_LOCAL -q "SELECT 1"