2018-01-09 20:20:13 +00:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
set -e
|
|
|
|
set -x
|
|
|
|
|
|
|
|
for PKG in $(ls /tmp/buildd/*.deb | sed -e's,.*/,,;s,_.*,,' ); do
|
|
|
|
apt-get install -y --force-yes "$PKG" || true
|
|
|
|
apt-get remove -y "$PKG" || true
|
|
|
|
done
|
|
|
|
|
|
|
|
dpkg -i /tmp/buildd/*.deb || true
|
|
|
|
apt install -y -f --allow-downgrades
|
|
|
|
|
|
|
|
|
2018-01-10 11:48:32 +00:00
|
|
|
# Some test references uses specific timezone
|
|
|
|
ln -fs /usr/share/zoneinfo/Europe/Moscow /etc/localtime
|
|
|
|
echo 'Europe/Moscow' > /etc/timezone
|
|
|
|
dpkg-reconfigure -f noninteractive tzdata
|
|
|
|
|
|
|
|
|
2018-01-09 20:20:13 +00:00
|
|
|
service clickhouse-server start
|
|
|
|
sleep 3
|
|
|
|
|
2018-01-15 18:57:10 +00:00
|
|
|
# TODO: remove me or make only on error:
|
|
|
|
tail -n100 /var/log/clickhouse-server/*
|
2018-01-09 20:20:13 +00:00
|
|
|
|
|
|
|
clickhouse-client -q "SELECT * from system.build_options;"
|
2018-01-10 11:48:32 +00:00
|
|
|
clickhouse-client -q "SELECT toDateTime(1);"
|
|
|
|
|
2018-01-09 20:20:13 +00:00
|
|
|
|
2018-01-15 18:57:10 +00:00
|
|
|
TEST_TRUE=${TEST_TRUE:=true}
|
|
|
|
|
2018-01-09 20:20:13 +00:00
|
|
|
# --no-shard because default server listen only :: and 127.0.0.1
|
2018-01-15 18:57:10 +00:00
|
|
|
[ -n "$TEST_RUN" ] && clickhouse-test --no-shard --queries /usr/share/clickhouse-test/queries --tmp /tmp/clickhouse-test/ $TEST_OPT || $TEST_TRUE
|
2018-01-09 20:20:13 +00:00
|
|
|
|
|
|
|
|
|
|
|
service clickhouse-server stop
|
2018-01-15 18:57:10 +00:00
|
|
|
|
|
|
|
# Test debug symbols
|
|
|
|
gdb -ex quit --args /usr/bin/clickhouse-server
|