2023-11-01 13:46:30 +00:00
|
|
|
if [ ! -f /root/.ssh/id_rsa.pub ] then
|
|
|
|
echo no ssh key, generate: rsa without password
|
|
|
|
exit 1
|
|
|
|
fi
|
2023-11-01 14:01:09 +00:00
|
|
|
|
2023-11-01 13:46:30 +00:00
|
|
|
echo
|
|
|
|
echo Add the following key to your remote sftp:
|
|
|
|
cat /root/.ssh/id_rsa.pub
|
|
|
|
echo
|
|
|
|
echo Press enter to continue
|
|
|
|
read
|
|
|
|
|
2023-11-01 13:46:38 +00:00
|
|
|
apt update
|
|
|
|
apt install -y python3 rclone fuse
|
|
|
|
|
2023-11-01 13:46:30 +00:00
|
|
|
cp -n rclone.conf /root/.config/rclone/rclone.conf
|
|
|
|
cp nman.service /etc/systemd/system/
|
|
|
|
cp nman.timer /etc/systemd/system/
|
|
|
|
cp mnt-nginx.mount /etc/systemd/system/
|
|
|
|
cp nman /etc/default/
|
|
|
|
cp nman.py /opt/
|
|
|
|
cp nman.sh /opt/
|
|
|
|
chmod +x /opt/nman.sh
|
|
|
|
|
|
|
|
systemctl stop nginx
|
|
|
|
|
|
|
|
rm -rf /etc/nginx
|
|
|
|
mkdir /etc/nginx
|
|
|
|
|
|
|
|
systemctl enable --now mnt-nginx.mount
|
|
|
|
|
|
|
|
/opt/nman.sh
|
|
|
|
|
|
|
|
systemctl enable nman.timer
|
|
|
|
systemctl start nginx
|