Files
rclone/fstest/testserver/init.d/TestWebdavOwncloud
T
Nick Craig-Wood ba11197157 fstest: move the Sia and Owncloud test servers out of the ephemeral port range
Their fixed ports, 39980 and 38081, are in Linux's ephemeral range
(32768-60999), so a socket from another concurrent test could hold
them and stop the server starting. This made all 5 tries of the Sia
fs/operations tests fail with "address already in use".
2026-10-31 17:22:39 +00:00

34 lines
849 B
Bash
Executable File

#!/usr/bin/env bash
set -e
NAME=owncloud
USER=rclone
PASS=HarperGrayerFewest5
PORT=28641
. $(dirname "$0")/docker.bash
start() {
docker run --rm -d --name $NAME \
-e "OWNCLOUD_DOMAIN=localhost:8080" \
-e "OWNCLOUD_DB_TYPE=sqlite" \
-e "OWNCLOUD_DB_NAME=owncloud.db" \
-e "OWNCLOUD_ADMIN_USERNAME=$USER" \
-e "OWNCLOUD_ADMIN_PASSWORD=$PASS" \
-e "OWNCLOUD_MYSQL_UTF8MB4=true" \
-e "OWNCLOUD_REDIS_ENABLED=false" \
-e "OWNCLOUD_TRUSTED_DOMAINS=127.0.0.1" \
-p 127.0.0.1:${PORT}:8080 \
owncloud/server
echo type=webdav
echo url=http://127.0.0.1:${PORT}/remote.php/webdav/
echo user=$USER
echo pass=$(rclone obscure $PASS)
echo vendor=owncloud
echo _connect=127.0.0.1:${PORT}
}
. $(dirname "$0")/run.bash