Implement upload/download limits, disable_verify_certificates config keys

This commit is contained in:
flow.gunso
2019-12-30 10:09:06 +01:00
parent 8e33c7431e
commit 9f526467fe
2 changed files with 38 additions and 4 deletions

View File

@@ -31,5 +31,12 @@ while [ ! -f $seafile_ini ]; do sleep 1; done
/usr/bin/seaf-cli start
while [ ! -S $seafile_sock ]; do sleep 1; done
# Set the disable_verify_certificate key to true only if the environment variable is true.
test "$SEAF_SKIP_SSL_CERT" = true && seaf-cli config -k disable_verify_certificate -v true
# Set the upload/download limits
test -n "$SEAF_UPLOAD_LIMIT" && seaf-cli config -k upload_limit -v $SEAF_UPLOAD_LIMIT
test -n "$SEAF_DOWNLOAD_LIMIT" && seaf-cli config -k download_limit -v $SEAF_DOWNLOAD_LIMIT
# Start the synchronisation.
/usr/bin/seaf-cli sync -u $SEAF_USERNAME -p $SEAF_PASSWORD -s $SEAF_SERVER_URL -l $SEAF_LIBRARY_UUID -d /volume