1
0
mirror of https://github.com/zokradonh/kopano-docker synced 2025-06-06 15:36:40 +00:00

Add wrapper scripts to easily get admin.cfg (#331)

* add small wrapper scripts to honor admin.cfg at /tmp/kopano
* add script to create stores (workaround to satisfy tests)
* add output of orphaned store list to startup test
This commit is contained in:
Felix Bartels 2020-02-04 08:07:49 +01:00 committed by GitHub
parent 4941b651b8
commit 8d0a0fd8f5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 22 additions and 3 deletions

3
core/bin/kopano-admin Executable file
View File

@ -0,0 +1,3 @@
#!/bin/bash
/usr/sbin/kopano-admin --config /tmp/kopano/admin.cfg "$@"

3
core/bin/kopano-cli Executable file
View File

@ -0,0 +1,3 @@
#!/bin/bash
/usr/sbin/kopano-cli --config /tmp/kopano/admin.cfg "$@"

View File

@ -0,0 +1,5 @@
#!/bin/bash
for kuser in $(kopano-storeadm -O | grep -A999999999 "Entities without stores:" | tail -n +4 | awk '{print $2}'); do
kopano-storeadm -n "$kuser" -C
done

3
core/bin/kopano-storeadm Executable file
View File

@ -0,0 +1,3 @@
#!/bin/bash
/usr/sbin/kopano-storeadm -c /tmp/kopano/admin.cfg "$@"

View File

@ -23,7 +23,8 @@ done
dockerize \
-wait tcp://kopano_server:236 \
-timeout 360s
echo "creating public store"
echo "Creating public store"
docker exec kopano_server kopano-storeadm -h default: -P || true
echo "Running sheduled cron jobs once"

View File

@ -29,9 +29,13 @@ docker exec kopano_server kopano-storeadm -h default: -P || true
docker exec kopano_server kopano-admin --sync
docker exec kopano_server kopano-cli --list-users
docker exec kopano_server kopano-storeadm -O # list users without a store
docker exec kopano_server kopano-admin -l
docker exec kopano_zpush z-push-admin -a list
docker exec kopano_zpush z-push-gabsync -a sync
# will print nothing if store exists and fail if it doen't
# FIXME temporary workaround for issue where kopano-admin --sync is not properly creating stores
docker exec kopano_server kopano-create-missing-stores.sh || true
# will print nothing if store exists and fail if it doesn't
docker exec kopano_server kopano-admin --details user1 | grep -q "^Store GUID:"

View File

@ -47,7 +47,7 @@ RUN \
curl -s -S -L -o - "${KOPANO_ZPUSH_REPOSITORY_URL}/Release.key" | apt-key add - && \
# install
set -x && \
# TODO set IGNORE_FIXSTATES_ON_UPGRADE https://jira.z-hub.io/browse/ZP-1164?jql=text%20~%20%22IGNORE_FIXSTATES_ON_UPGRADE%22
# TODO set IGNORE_FIXSTATES_ON_UPGRADE https://jira.z-hub.io/browse/ZP-1164
apt-get update && apt-get install -y --no-install-recommends \
apache2 \
libapache2-mod-php7.0 \