1
0
mirror of https://github.com/checktheroads/hyperglass synced 2024-05-11 05:55:08 +00:00

fix backend ci test

This commit is contained in:
checktheroads
2021-01-04 00:46:30 -07:00
parent 938ad75435
commit 4e9351eede
2 changed files with 9 additions and 6 deletions

View File

@@ -13,8 +13,6 @@ jobs:
python-version: [3.6, 3.8] python-version: [3.6, 3.8]
os: [ubuntu-20.04] os: [ubuntu-20.04]
runs-on: ${{ matrix.os }} runs-on: ${{ matrix.os }}
env:
POETRY_HYPERGLASS_UI_BUILD_TIMEOUT: 600
steps: steps:
- name: Git Checkout - name: Git Checkout

View File

@@ -2,8 +2,11 @@
LOG_FILE="$HOME/hyperglass-ci.log" LOG_FILE="$HOME/hyperglass-ci.log"
export POETRY_HYPERGLASS_UI_BUILD_TIMEOUT="600"
echo "[INFO] Set build timeout to $POETRY_HYPERGLASS_UI_BUILD_TIMEOUT seconds"
echo "[INFO] Starting setup..." echo "[INFO] Starting setup..."
poetry run hyperglass setup -d poetry run hyperglass setup -d &> $LOG_FILE
echo "[SUCCESS] Setup completed." echo "[SUCCESS] Setup completed."
sleep 2 sleep 2
@@ -14,10 +17,11 @@ echo "[INFO] Setting listen_address..."
echo "listen_address: 127.0.0.1" >> $HOME/hyperglass/hyperglass.yaml echo "listen_address: 127.0.0.1" >> $HOME/hyperglass/hyperglass.yaml
echo "[INFO] Starting UI build." echo "[INFO] Starting UI build."
poetry run hyperglass build-ui poetry run hyperglass build-ui &> $LOG_FILE
if [[ ! $? == 0 ]]; then if [[ ! $? == 0 ]]; then
echo "[ERROR] Failed to start hyperglass." echo "[ERROR] Failed to build hyperglass ui."
cat /tmp/hyperglass.log
exit 1 exit 1
else else
echo "[SUCCESS] UI build completed." echo "[SUCCESS] UI build completed."
@@ -29,6 +33,7 @@ sleep 120
if [[ ! $? == 0 ]]; then if [[ ! $? == 0 ]]; then
echo "[ERROR] Failed to start hyperglass." echo "[ERROR] Failed to start hyperglass."
cat /tmp/hyperglass.log
exit 1 exit 1
else else
echo "[SUCCESS] Started hyperglass." echo "[SUCCESS] Started hyperglass."
@@ -44,7 +49,7 @@ if [[ ! $? == 0 ]]; then
echo "[ERROR] HTTP test failed." echo "[ERROR] HTTP test failed."
exit 1 exit 1
elif [[ ! "$STATUS" == "200" ]]; then elif [[ ! "$STATUS" == "200" ]]; then
echo "[ERROR] HTTP test failed. Startup log:" echo "[ERROR] HTTP test failed."
cat $LOG_FILE cat $LOG_FILE
exit 1 exit 1
fi fi