-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
37 lines (30 loc) · 954 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
FROM centos:7
LABEL maintainer="[email protected]"
LABEL Description="Based on fauria/docker-vsftpd. vsftpd Docker image based on Centos 7. Supports passive mode and virtual users." \
License="Apache License 2.0" \
Usage="docker run -d -p [HOST PORT NUMBER]:21 -v [HOST FTP HOME]:/home/vsftpd netant1983/vsftpd" \
Version="1.0"
RUN yum -y update && yum clean all
RUN yum install -y \
vsftpd \
db4-utils \
db4 && yum clean all
ENV FTP_USER **String**
ENV FTP_PASS **Random**
ENV PASV_ADDRESS **IPv4**
ENV PASV_MIN_PORT 21100
ENV PASV_MAX_PORT 21110
ENV LOG_STDOUT **Boolean**
ENV LOCAL_UMASK **String**
ENV FILE_OPEN_MODE **String**
ENV PASV_ADDR_RESOLVE **Boolean**
COPY vsftpd.conf /etc/vsftpd/
COPY vsftpd_virtual /etc/pam.d/
COPY run-vsftpd.sh /usr/sbin/
RUN chmod +x /usr/sbin/run-vsftpd.sh
RUN mkdir -p /home/vsftpd/
RUN chown -R ftp:ftp /home/vsftpd/
VOLUME /home/vsftpd
VOLUME /var/log/vsftpd
EXPOSE 20 21
CMD ["/usr/sbin/run-vsftpd.sh"]