initial commit

This commit is contained in:
2020-08-04 17:46:51 +02:00
commit a93599babe
1480 changed files with 310969 additions and 0 deletions

36
ins-instructions.txt Normal file
View File

@@ -0,0 +1,36 @@
###WARNING:###
#this system does not do version management an also syncs deletions from remote mailserver
#make sure version managent and/or backups and/or snapshots are setup!!
###
#clone this project
#Apt list
apt install -y dovecot-imapd nginx php7.3-xml php7.3-fpm php7.3-curl offlineimap sudo
#dirs and perms
mkdir /mail
chmod 777 /mail
chown www-data:www-data -R /var/www
#place all configfiles to the repective location
#restart services or the system
systemctl enable nginx dovecot
systemctl stop nginx dovecot
systemctl start nginx dovecot
#Setup cronjobs
# Explenation of job definition:
# .---------------- minute (0 - 59)
# | .------------- hour (0 - 23)
# | | .---------- day of month (1 - 31)
# | | | .------- month (1 - 12) OR jan,feb,mar,apr ...
# | | | | .---- day of week (0 - 6) (Sunday=0 or 7) OR sun,mon,tue,wed,thu,fri,sat
# | | | | |
# * * * * *
echo '30 2 * * 4 root bash /opt/BackupUtil/Backup-Util.sh >/dev/null 2>&1' >> /etc/crontab
#add user/sync job
adduser <localname>
#replace <username> with the the chosen localname and update the remote IMAP settings
#for ease to acces edit /var/www/index.html and add the new credentials
nano /home/<localname>/.offlineimaprc
echo "sudo -u <localname> offlineimap" >> /opt/mailsync.sh