A simple FTP server, using
vsftpd
.
To start a container, with data stored in /data
on the host, use the
following:
docker run
docker run \
--detach \
--env FTP_PASS=123 \
--env FTP_USER=user \
--name my-ftp-server \
--publish 20-21:20-21/tcp \
--publish 40000-40009:40000-40009/tcp \
--volume /data:/home/user \
garethflowers/ftp-server
docker compose
services:
ftp-server:
container_name: my-ftp-server
environment:
- FTP_PASS=123
- FTP_USER=user
image: garethflowers/ftp-server
ports:
- '20-21:20-21/tcp'
- '40000-40009:40000-40009/tcp' # Only needed for passive mode
volumes:
- '/data:/home/user'