zammad-docker-compose/.github/tests.sh
André Bauer 9eda319ed3
use port 8080 for nginx (#193)
* use port 8080 for nginx

Signed-off-by: André Bauer <monotek23@gmail.com>

* fix test

Signed-off-by: André Bauer <monotek23@gmail.com>

* fix port in override file

Signed-off-by: André Bauer <monotek23@gmail.com>

* fix logging

Signed-off-by: André Bauer <monotek23@gmail.com>

* fix compose cmd

Signed-off-by: André Bauer <monotek23@gmail.com>

* fix ci timeout

Signed-off-by: André Bauer <monotek23@gmail.com>
2021-03-18 21:53:46 +01:00

40 lines
725 B
Bash
Executable File

#!/bin/bash
#
# run zammad tests
#
set -o errexit
set -o pipefail
docker-compose logs --timestamps --follow &
until (curl -I --silent --fail localhost:8080 | grep -iq "HTTP/1.1 200 OK"); do
echo "wait for zammad to be ready..."
sleep 15
done
sleep 30
echo
echo "Success - Zammad is up :)"
echo
echo
echo "Execute autowizard..."
echo
docker exec zammad-docker-compose_zammad-railsserver_1 rake zammad:setup:auto_wizard
echo
echo "Autowizard executed successful :)"
echo
echo
echo "Fill DB with some random data"
docker exec zammad-docker-compose_zammad-railsserver_1 rails r "FillDB.load(agents: 1,customers: 1,groups: 1,organizations: 1,overviews: 1,tickets: 1)"
echo
echo "DB fill successful :)"
echo