rclone/fstest/testserver/init.d/TestSMB
Nick Craig-Wood 8dc4c01209 build: make integration tests run better on macOS and Windows
This changes as many of the integraton tests as possible so that they
use port forwarding rather than the docker IP directly.

Using the docker IP directly does not work on macOS and Windows as the
docker images are running in a VM rather than a container.

This adds the PORTS.md document to document which port numbers we are
using for which service as they need to be unique.
2024-04-16 10:48:48 +01:00

34 lines
649 B
Bash
Executable File

#!/bin/bash
set -e
NAME=smb
USER=rclone
PASS=GNF3Cqeu
WORKGROUP=thepub
PORT=28630
. $(dirname "$0")/docker.bash
start() {
docker run --rm -d --name $NAME \
-p 127.0.0.1:${PORT}:445 \
-p 127.0.0.1:${PORT}:445/udp \
dperson/samba \
-p \
-u "rclone;${PASS}" \
-w "${WORKGROUP}" \
-s "public;/share" \
-s "rclone;/rclone;yes;no;no;rclone"
echo type=smb
echo host=127.0.0.1
echo user=$USER
echo port=$PORT
echo pass=$(rclone obscure $PASS)
echo domain=$WORKGROUP
echo _connect=127.0.0.1:${PORT}
}
. $(dirname "$0")/run.bash