mirror of
https://github.com/elastic/kibana.git
synced 2025-04-23 09:19:04 -04:00
* [package testing] Show kibana logs on exit
* fix syntax
* fix syntax
* fix
* use absolute path
* wrap in fn
(cherry picked from commit 0300e02718
)
Co-authored-by: Jonathan Budzenski <jon@elastic.co>
Co-authored-by: Spencer <spencer@elastic.co>
This commit is contained in:
parent
1f2ccb1f2e
commit
3f86f900e3
1 changed files with 11 additions and 1 deletions
|
@ -20,7 +20,7 @@ elif [[ "$TEST_PACKAGE" == "docker" ]]; then
|
|||
fi
|
||||
cd ..
|
||||
|
||||
export VAGRANT_CWD=test/package
|
||||
export VAGRANT_CWD=$PWD/test/package
|
||||
vagrant up "$TEST_PACKAGE" --no-provision
|
||||
|
||||
node scripts/es snapshot \
|
||||
|
@ -29,6 +29,16 @@ node scripts/es snapshot \
|
|||
--license=trial &
|
||||
while ! timeout 1 bash -c "echo > /dev/tcp/localhost/9200"; do sleep 30; done
|
||||
|
||||
function echoKibanaLogs {
|
||||
echo '--- Kibana logs'
|
||||
if [[ "$TEST_PACKAGE" == "deb" ]] || [[ "$TEST_PACKAGE" == "rpm" ]]; then
|
||||
vagrant ssh $TEST_PACKAGE -t -c 'sudo cat /var/log/kibana/kibana.log'
|
||||
elif [[ "$TEST_PACKAGE" == "docker" ]]; then
|
||||
vagrant ssh $TEST_PACKAGE -t -c 'sudo docker logs kibana'
|
||||
fi
|
||||
}
|
||||
trap "echoKibanaLogs" EXIT
|
||||
|
||||
vagrant provision "$TEST_PACKAGE"
|
||||
|
||||
export TEST_BROWSER_HEADLESS=1
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue