1.拉取镜像
代码语言:text复制docker pull fauria/vsftpd
2.docker-compose
部署
version: "3"
services:
vsftpd:
image: "fauria/vsftpd"
container_name: vsftpd
volumes:
- ./vsftp/:/home/vsftpd
ports:
- "21:21"
- "21100-21110:21100-21110"
environment:
- FTP_USER=root
- FTP_PASS=root
- PASV_ADDRESS=127.0.0.1
- PASV_MIN_PORT=21100
- PASV_MAX_PORT=21110
deploy:
resources:
limits:
cpus: '0.2'
memory: 512M
reservations:
cpus: '0.2'
memory: 512M
代码语言:text复制docker-compose -f ftp.yaml up [-d]