mirror of
https://github.com/ggogel/seafile-containerized.git
synced 2024-11-16 17:05:32 +00:00
stop / start socat in gc.sh
This commit is contained in:
parent
8b658bd755
commit
e9771dcb83
|
@ -1,9 +1,11 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
set -e
|
set -e
|
||||||
|
source /scripts/utils.sh
|
||||||
SEAFILE_DIR=/opt/seafile/seafile-server-latest
|
SEAFILE_DIR=/opt/seafile/seafile-server-latest
|
||||||
|
|
||||||
if [[ $SEAFILE_SERVER != *"pro"* ]]; then
|
if [[ $SEAFILE_SERVER != *"pro"* ]]; then
|
||||||
echo "Seafile CE: Stop Seafile to perform offline garbage collection."
|
echo "Seafile CE: Stop Seafile to perform offline garbage collection."
|
||||||
|
stop_socat
|
||||||
$SEAFILE_DIR/seafile.sh stop
|
$SEAFILE_DIR/seafile.sh stop
|
||||||
echo "Waiting for the server to shut down properly..."
|
echo "Waiting for the server to shut down properly..."
|
||||||
sleep 5
|
sleep 5
|
||||||
|
@ -18,8 +20,9 @@ fi
|
||||||
) gc_exit_code=$?
|
) gc_exit_code=$?
|
||||||
|
|
||||||
if [[ $SEAFILE_SERVER != *"pro"* ]]; then
|
if [[ $SEAFILE_SERVER != *"pro"* ]]; then
|
||||||
echo "Giving the server some time..."
|
echo "Seafile CE: Offline garbage collection completed. Starting Seafile."
|
||||||
sleep 3
|
sleep 3
|
||||||
$SEAFILE_DIR/seafile.sh start
|
$SEAFILE_DIR/seafile.sh start
|
||||||
|
start_socat
|
||||||
fi
|
fi
|
||||||
exit $gc_exit_code
|
exit $gc_exit_code
|
||||||
|
|
Loading…
Reference in a new issue