'install-photo-import-tool.sh' updaten

This commit is contained in:
2019-06-05 22:13:14 +00:00
parent 29ad252b15
commit 887f1b3598

View File

@@ -1,18 +1,5 @@
#!/usr/bin/env bash #!/usr/bin/env bash
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
echo "----------------------" echo "----------------------"
echo "Updating the system..." echo "Updating the system..."
echo "----------------------" echo "----------------------"
@@ -25,21 +12,15 @@ echo "-----------------------------------"
echo "Installing the required packages..." echo "Installing the required packages..."
echo "-----------------------------------" echo "-----------------------------------"
apt install acl screen rsync exfat-fuse exfat-utils ntfs-3g gphoto2 libimage-exiftool-perl dialog php cifs-utils sudo -y apt install acl screen rsync exfat-fuse exfat-utils ntfs-3g gphoto2 libimage-exiftool-perl php cifs-utils sudo -y
USER="root" echo "-----------------------------"
echo "Setting-up Server-APP..."
echo "-----------------------------"
mkdir /media/card mkdir /media/card
echo "-----------------------------"
echo "Fetching Little Backup Box..."
echo "-----------------------------"
cd
git clone https://trans.bprieshof.nl/gitea/brammp/little-backup-box-Bram.git
mkdir /mnt/SMB mkdir /mnt/SMB
cat > /etc/network/if-up.d/mountsmb <<- "EOF" cat > /etc/network/if-up.d/mountsmb <<- "EOF"
#! /bin/sh #! /bin/sh
mount -t cifs -o username=import,password=importpw,iocharset=utf8,sec=ntlmssp,file_mode=0775,dir_mode=0775 //192.168.2.144/Data /mnt/SMB mount -t cifs -o username=import,password=importpw,iocharset=utf8,sec=ntlmssp,file_mode=0775,dir_mode=0775 //192.168.2.144/Data /mnt/SMB
@@ -48,7 +29,7 @@ EOF
cat > /etc/network/if-up.d/startphpweb <<- "EOF" cat > /etc/network/if-up.d/startphpweb <<- "EOF"
#! /bin/sh #! /bin/sh
cd /root/little-backup-box-Bram/scripts && php -S 0.0.0.0:8000 & cd /root/Server-APP/scripts && php -S 0.0.0.0:8000 &
exit 0 exit 0
EOF EOF
@@ -56,4 +37,4 @@ echo "---------------------------------------------"
echo "All done! The system will reboot in 1 minute." echo "All done! The system will reboot in 1 minute."
echo "---------------------------------------------" echo "---------------------------------------------"
shutdown -r 1 shutdown -r 1