forked from crony/UpFast
Compare commits
2 Commits
c3f133b211
...
a4d9291ee3
Author | SHA1 | Date | |
---|---|---|---|
|
a4d9291ee3 | ||
|
129101ac2e |
19
install.sh
19
install.sh
@ -6,16 +6,19 @@ then
|
|||||||
echo "Please run as root"
|
echo "Please run as root"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
SIZE="5G"
|
||||||
|
|
||||||
useradd --shell /bin/sh --system --home-dir /usr/local/upfast upfast ||
|
UFDIR=${1:=/srv/upfast}
|
||||||
|
USER=${1:=upfast}
|
||||||
|
useradd --shell /bin/sh --system --home-dir $UFDIR $UFUSER ||
|
||||||
exit 1
|
exit 1
|
||||||
mkdir -p /usr/local/upfast || # dodge copying of skeletons
|
mkdir -p "$UFDIR" || # dodge copying of skeletons
|
||||||
exit 1
|
exit 1
|
||||||
|
|
||||||
chown upfast:upfast /usr/local/upfast
|
chown "$UFUSER:$UFUSER" "$UFDIR"
|
||||||
chmod 700 /usr/local/upfast
|
chmod 700 "$UFDIR"
|
||||||
|
|
||||||
su upfast -c'
|
su "$UFUSER" -c"
|
||||||
cd
|
cd
|
||||||
git clone https://code.cronyakatsuki.xyz/tlast/upfast . ||
|
git clone https://code.cronyakatsuki.xyz/tlast/upfast . ||
|
||||||
exit 1
|
exit 1
|
||||||
@ -25,7 +28,11 @@ python3 -m venv env
|
|||||||
exit1
|
exit1
|
||||||
pip install -r requirements.txt ||
|
pip install -r requirements.txt ||
|
||||||
exit 1
|
exit 1
|
||||||
mkdir upload' ||
|
|
||||||
|
fallocate -l $SIZE storage
|
||||||
|
mkfs.ext4 storage
|
||||||
|
mount storage upload
|
||||||
|
rm -fd /storage/*" ||
|
||||||
exit 1
|
exit 1
|
||||||
|
|
||||||
cp ./upfast.service /etc/systemd/system/upfast.service
|
cp ./upfast.service /etc/systemd/system/upfast.service
|
||||||
|
Loading…
Reference in New Issue
Block a user