first commit
This commit is contained in:
3
.gitignore
vendored
Normal file
3
.gitignore
vendored
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
/*.pkg.tar.zst
|
||||||
|
/src/
|
||||||
|
/pkg/
|
||||||
36
PKGBUILD
Normal file
36
PKGBUILD
Normal file
@@ -0,0 +1,36 @@
|
|||||||
|
# Maintainer: zj <1052308357@qq.com>
|
||||||
|
|
||||||
|
pkgname=tms-pure-ftpd-config
|
||||||
|
pkgver=1.0
|
||||||
|
pkgrel=2
|
||||||
|
pkgdesc="pure-ftpd tms conifg."
|
||||||
|
arch=('x86_64')
|
||||||
|
url="https://yuyujing.cn"
|
||||||
|
license=('Proprietary')
|
||||||
|
|
||||||
|
depends=('pure-ftpd')
|
||||||
|
|
||||||
|
source=("${pkgname}.tar.gz")
|
||||||
|
|
||||||
|
sha256sums=('8dbe66b1d2a0059776274451c510b67949110c853a2fdc8cbd05c63f53d4f9cf')
|
||||||
|
|
||||||
|
install="${pkgname}.install"
|
||||||
|
|
||||||
|
prepare() {
|
||||||
|
cd "${srcdir}/${pkgname}"
|
||||||
|
}
|
||||||
|
|
||||||
|
build() {
|
||||||
|
msg "No build step required for this package."
|
||||||
|
}
|
||||||
|
|
||||||
|
package() {
|
||||||
|
|
||||||
|
local _config_base_dir="/etc/pure-ftpd"
|
||||||
|
install -d -m755 "${pkgdir}${_config_base_dir}"
|
||||||
|
|
||||||
|
cd "${srcdir}/${pkgname}"
|
||||||
|
|
||||||
|
cp -r pure-ftpd/* "${pkgdir}${_config_base_dir}/"
|
||||||
|
|
||||||
|
}
|
||||||
31
tms-pure-ftpd-config.install
Normal file
31
tms-pure-ftpd-config.install
Normal file
@@ -0,0 +1,31 @@
|
|||||||
|
# pre_install 钩子在安装文件复制到系统之前运行
|
||||||
|
pre_install() {
|
||||||
|
echo "Checking pure-ftpd config and remove"
|
||||||
|
mv /etc/pure-ftpd/pure-ftpd.conf /etc/pure-ftpd/pure-ftpd.conf.bakup
|
||||||
|
mv /etc/pure-ftpd/welcome.msg /etc/pure-ftpd/welcome.msg.bakup
|
||||||
|
rm -f /etc/pureftpd.pdb
|
||||||
|
rm -f /etc/pureftpd.passwd
|
||||||
|
rm -f /etc/pure-ftpd.conf
|
||||||
|
}
|
||||||
|
|
||||||
|
# post_install: 在软件包安装后执行
|
||||||
|
post_install() {
|
||||||
|
echo "start pure-ftpd.service"
|
||||||
|
systemctl start pure-ftpd.service
|
||||||
|
systemctl enable pure-ftpd.service
|
||||||
|
}
|
||||||
|
|
||||||
|
# pre_remove: 在软件包卸载前执行
|
||||||
|
pre_remove() {
|
||||||
|
echo "Stopping and disabling pure-ftpd.service..."
|
||||||
|
systemctl stop pure-ftpd.service
|
||||||
|
systemctl disable pure-ftpd.service
|
||||||
|
}
|
||||||
|
|
||||||
|
# post_remove: 在软件包卸载后执行
|
||||||
|
post_remove() {
|
||||||
|
echo "Reloading systemd configuration after removal..."
|
||||||
|
[ -f /etc/pure-ftpd/pure-ftpd.conf.bakup ] && mv /etc/pure-ftpd/pure-ftpd.conf.bakup /etc/pure-ftpd/pure-ftpd.conf
|
||||||
|
[ -f /etc/pure-ftpd/welcome.msg.bakup ] && mv /etc/pure-ftpd/welcome.msg.bakup /etc/pure-ftpd/welcome.msg
|
||||||
|
|
||||||
|
}
|
||||||
BIN
tms-pure-ftpd-config.tar.gz
Normal file
BIN
tms-pure-ftpd-config.tar.gz
Normal file
Binary file not shown.
31
tms-pure-ftpd-config/pure-ftpd/pure-ftpd.conf
Normal file
31
tms-pure-ftpd-config/pure-ftpd/pure-ftpd.conf
Normal file
@@ -0,0 +1,31 @@
|
|||||||
|
ChrootEveryone yes
|
||||||
|
BrokenClientsCompatibility no
|
||||||
|
MaxClientsNumber 100
|
||||||
|
Daemonize yes
|
||||||
|
MaxClientsPerIP 8
|
||||||
|
VerboseLog no
|
||||||
|
DisplayDotFiles no
|
||||||
|
AnonymousOnly no
|
||||||
|
NoAnonymous no
|
||||||
|
SyslogFacility ftp
|
||||||
|
DontResolve yes
|
||||||
|
MaxIdleTime 15
|
||||||
|
PureDB /etc/pure-ftpd/pureftpd.pdb
|
||||||
|
PAMAuthentication yes
|
||||||
|
LimitRecursion 10000 8
|
||||||
|
AnonymousCanCreateDirs no
|
||||||
|
MaxLoad 4
|
||||||
|
# PassivePortRange 30000 50000
|
||||||
|
AntiWarez yes
|
||||||
|
Umask 133:022
|
||||||
|
MinUID 1000
|
||||||
|
AllowUserFXP no
|
||||||
|
AllowAnonymousFXP no
|
||||||
|
ProhibitDotFilesWrite yes
|
||||||
|
ProhibitDotFilesRead yes
|
||||||
|
AutoRename no
|
||||||
|
AnonymousCantUpload yes
|
||||||
|
AltLog clf:/var/log/pureftpd.log
|
||||||
|
MaxDiskUsage 99
|
||||||
|
CustomerProof yes
|
||||||
|
IPV4Only yes
|
||||||
2
tms-pure-ftpd-config/pure-ftpd/pureftpd.passwd
Normal file
2
tms-pure-ftpd-config/pure-ftpd/pureftpd.passwd
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
tms:$argon2id$v=19$m=8192,t=511,p=1$XOyXf4pgs/PgfyJWHJuT9Q$j6PWu8V1IIeQxTsnMt4soJYt9p6swQCei72I6WGEe4Q:1001:1001::/media/cinema/./::::::::::::
|
||||||
|
kdm:$argon2id$v=19$m=8192,t=511,p=1$SMpF8Bh3VuO+4A+fzn8XZA$uWbxeraghIP26a6+8ABf3r14zKHn0v/Z7mzINaU1F74:1002:1002::/media/kdm/./::::::::::::
|
||||||
BIN
tms-pure-ftpd-config/pure-ftpd/pureftpd.pdb
Normal file
BIN
tms-pure-ftpd-config/pure-ftpd/pureftpd.pdb
Normal file
Binary file not shown.
1
tms-pure-ftpd-config/pure-ftpd/welcome.msg
Normal file
1
tms-pure-ftpd-config/pure-ftpd/welcome.msg
Normal file
@@ -0,0 +1 @@
|
|||||||
|
Welcome to the FTP server.
|
||||||
68
up+.sh
Executable file
68
up+.sh
Executable file
@@ -0,0 +1,68 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
#set -e
|
||||||
|
##################################################################################################################
|
||||||
|
# Author : Erik Dubois
|
||||||
|
# Website : https://www.erikdubois.be
|
||||||
|
# Website : https://www.alci.online
|
||||||
|
# Website : https://www.ariser.eu
|
||||||
|
# Website : https://www.arcolinux.info
|
||||||
|
# Website : https://www.arcolinux.com
|
||||||
|
# Website : https://www.arcolinuxd.com
|
||||||
|
# Website : https://www.arcolinuxb.com
|
||||||
|
# Website : https://www.arcolinuxiso.com
|
||||||
|
# Website : https://www.arcolinuxforum.com
|
||||||
|
##################################################################################################################
|
||||||
|
#
|
||||||
|
# DO NOT JUST RUN THIS. EXAMINE AND JUDGE. RUN AT YOUR OWN RISK.
|
||||||
|
#
|
||||||
|
##################################################################################################################
|
||||||
|
#tput setaf 0 = black
|
||||||
|
#tput setaf 1 = red
|
||||||
|
#tput setaf 2 = green
|
||||||
|
#tput setaf 3 = yellow
|
||||||
|
#tput setaf 4 = dark blue
|
||||||
|
#tput setaf 5 = purple
|
||||||
|
#tput setaf 6 = cyan
|
||||||
|
#tput setaf 7 = gray
|
||||||
|
#tput setaf 8 = light blue
|
||||||
|
##################################################################################################################
|
||||||
|
|
||||||
|
# reset - commit your changes or stash them before you merge
|
||||||
|
# git reset --hard - personal alias - grh
|
||||||
|
|
||||||
|
echo "Deleting the work folder if one exists"
|
||||||
|
[ -d work ] && rm -rf work
|
||||||
|
|
||||||
|
# checking if I have the latest files from github
|
||||||
|
echo "Checking for newer files online first"
|
||||||
|
git pull
|
||||||
|
|
||||||
|
# Below command will backup everything inside the project folder
|
||||||
|
git add --all .
|
||||||
|
|
||||||
|
# Give a comment to the commit if you want
|
||||||
|
echo "####################################"
|
||||||
|
echo "Write your commit comment!"
|
||||||
|
echo "####################################"
|
||||||
|
|
||||||
|
read input
|
||||||
|
|
||||||
|
# Committing to the local repository with a message containing the time details and commit text
|
||||||
|
|
||||||
|
git commit -m "$input"
|
||||||
|
|
||||||
|
# Push the local files to github
|
||||||
|
|
||||||
|
if grep -q main .git/config; then
|
||||||
|
echo "Using main"
|
||||||
|
git push -u origin main
|
||||||
|
fi
|
||||||
|
|
||||||
|
if grep -q master .git/config; then
|
||||||
|
echo "Using master"
|
||||||
|
git push -u origin master
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "################################################################"
|
||||||
|
echo "################### Git Push Done ######################"
|
||||||
|
echo "################################################################"
|
||||||
Reference in New Issue
Block a user