rclone/fstest/testserver/init.d
Nick Craig-Wood fada870ff0 testserver: fix owncloud test server startup 2025-11-10 16:57:18 +00:00
..
TestSwiftAIO.d build: Bump SwiftAIO container to a newer one 2025-10-06 16:55:48 +01:00
seafile seafile: renew library password - fixes #6662 2023-01-15 16:26:29 +00:00
PORTS.md testserver: make sure TestWebdavInfiniteScale uses an assigned port 2025-11-05 17:56:28 +00:00
README.md testserver: remind developers about allocating a port 2025-11-05 17:56:28 +00:00
TestFTPProftpd tree-wide: replace /bin/bash with /usr/bin/env bash 2024-06-11 12:47:47 +01:00
TestFTPPureftpd tree-wide: replace /bin/bash with /usr/bin/env bash 2024-06-11 12:47:47 +01:00
TestFTPRclone tree-wide: replace /bin/bash with /usr/bin/env bash 2024-06-11 12:47:47 +01:00
TestFTPVsftpd tree-wide: replace /bin/bash with /usr/bin/env bash 2024-06-11 12:47:47 +01:00
TestFTPVsftpdTLS tree-wide: replace /bin/bash with /usr/bin/env bash 2024-06-11 12:47:47 +01:00
TestHdfs testserver: fix HDFS server after run.bash adjustments 2025-11-05 17:56:28 +00:00
TestS3Exaba s3: add Exaba provider 2025-06-04 17:42:48 +01:00
TestS3Minio tree-wide: replace /bin/bash with /usr/bin/env bash 2024-06-11 12:47:47 +01:00
TestS3MinioEdge tree-wide: replace /bin/bash with /usr/bin/env bash 2024-06-11 12:47:47 +01:00
TestS3Rclone tree-wide: replace /bin/bash with /usr/bin/env bash 2024-06-11 12:47:47 +01:00
TestSFTPOpenssh tree-wide: replace /bin/bash with /usr/bin/env bash 2024-06-11 12:47:47 +01:00
TestSFTPRclone tree-wide: replace /bin/bash with /usr/bin/env bash 2024-06-11 12:47:47 +01:00
TestSFTPRcloneSSH tree-wide: replace /bin/bash with /usr/bin/env bash 2024-06-11 12:47:47 +01:00
TestSMB tree-wide: replace /bin/bash with /usr/bin/env bash 2024-06-11 12:47:47 +01:00
TestSMBKerberos test: fix smb kerberos integration tests 2025-07-09 18:05:29 +01:00
TestSMBKerberosCcache smb: add --smb-kerberos-ccache option to set kerberos ccache per smb backend 2025-07-10 10:17:42 +01:00
TestSeafile testserver: fix seafile servers messing up _connect string 2025-11-05 17:56:28 +00:00
TestSeafileEncrypted testserver: fix seafile servers messing up _connect string 2025-11-05 17:56:28 +00:00
TestSeafileV6 testserver: fix seafile servers messing up _connect string 2025-11-05 17:56:28 +00:00
TestSia tree-wide: replace /bin/bash with /usr/bin/env bash 2024-06-11 12:47:47 +01:00
TestSwiftAIO build: Bump SwiftAIO container to a newer one 2025-10-06 16:55:48 +01:00
TestSwiftAIOsegments build: Bump SwiftAIO container to a newer one 2025-10-06 16:55:48 +01:00
TestWebdavInfiniteScale testserver: make sure TestWebdavInfiniteScale uses an assigned port 2025-11-05 17:56:28 +00:00
TestWebdavNextcloud tree-wide: replace /bin/bash with /usr/bin/env bash 2024-06-11 12:47:47 +01:00
TestWebdavOwncloud testserver: fix owncloud test server startup 2025-11-10 16:57:18 +00:00
TestWebdavRclone tree-wide: replace /bin/bash with /usr/bin/env bash 2024-06-11 12:47:47 +01:00
docker.bash test_all: POSIX head/tail invocations 2024-11-20 18:02:07 +00:00
rclone-serve.bash tree-wide: replace /bin/bash with /usr/bin/env bash 2024-06-11 12:47:47 +01:00
run.bash testserver: make run.bash variables less likely to collide with scripts 2025-11-05 17:56:28 +00:00

README.md

This directory contains scripts to start and stop servers for testing.

The commands are named after the remotes in use. They are executable files with the following parameters:

start  - starts the server if not running
stop   - stops the server if nothing is using it
status - returns non-zero exit code if the server is not running
reset  - stops the server and resets any reference counts

These will be called automatically by test_all if that remote is required.

When start is run it should output config parameters for that remote. If a _connect parameter is output then that will be used for a connection test. For example if _connect=127.0.0.1:80 then a TCP connection will be made to 127.0.0.1:80 and only when that succeeds will the test continue.

If in addition to _connect, _connect_delay=5s is also present then after the connection succeeds rclone will wait 5s before continuing. This is for servers that aren't quite ready even though they have opened their TCP ports.

Writing new scripts

A docker based server or an rclone serve based server should be easy to write. Look at one of the examples.

run.bash contains boilerplate to be included in a bash script for interpreting the command line parameters. This does reference counting to ensure multiple copies of the server aren't running at once. Including this is mandatory. It will call your start(), stop() and status() functions.

docker.bash contains library functions to help with docker implementations. It contains implementations of stop() and status() so all you have to do is write a start() function.

rclone-serve.bash contains functions to help with rclone serve based implementations. It contains implementations of stop() and status() so all you have to do is write a start() function which should call the run() function provided.

Any external TCP or UDP ports used should be unique as any of the servers might be running together. So please create a new line in the PORTS file to allocate your server a port. Bind any ports to localhost so they aren't accessible externally.