-
Notifications
You must be signed in to change notification settings - Fork 15
Expand file tree
/
Copy pathvsftpd.sh
More file actions
30 lines (30 loc) · 733 Bytes
/
Copy pathvsftpd.sh
File metadata and controls
30 lines (30 loc) · 733 Bytes
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
#!/bin/bash
#Fast vsftpd install && config for Debian distro
aptitude update
aptitude install vsftpd -y
usermod -d /var/ftp ftp
rmdir /home/ftp
addgroup ftpuser
useradd -d /var/ftp -g ftpuser ftpuser
mkdir /var/ftp
mkdir /var/ftp/tmp
mkdir /var/ftp/tmp/torrents
chmod 555 /var/ftp
chmod 777 /var/ftp/tmp
chmod 777 /var/ftp/tmp/torrents
chown root:ftpuser /var/ftp
chown muzftp:ftpuser /var/ftp/tmp
cp /etc/vsftpd.conf /etc/vsftpd.conf_bak
cat /dev/null > /etc/vsftpd.conf
echo "listen=YES
anonymous_enable=NO
no_anon_password=NO
anon_root=/var/ftp/pub
anon_umask=022
local_enable=YES
write_enable=YES
local_umask=023
chroot_local_user=YES
chroot_list_enable=NO
xferlog_enable=YES
xferlog_file=/var/log/vsftpd.log" > /etc/vsftpd.conf