mirror of
https://github.com/adferrand/docker-backuppc.git
synced 2023-11-05 04:40:26 +01:00
Avoid to overwrite pre-defined /etc/msmtprc
This commit is contained in:
parent
650333e3aa
commit
d79dfd142d
@ -1,6 +1,10 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
## master - CURRENT
|
## master - CURRENT
|
||||||
|
### Added
|
||||||
|
* The system configuration file `/etc/msmtprc` for `msmtprc` is not overwritten
|
||||||
|
if it already exists at container initialization.
|
||||||
|
|
||||||
## 4.4.0-3 - 06/11/2020
|
## 4.4.0-3 - 06/11/2020
|
||||||
### Modified
|
### Modified
|
||||||
* Update base image to Alpine 3.12.1
|
* Update base image to Alpine 3.12.1
|
||||||
|
@ -106,6 +106,7 @@ if [ -f /firstrun ]; then
|
|||||||
touch /var/log/lighttpd/error.log && chown -R "$BACKUPPC_USERNAME":"$BACKUPPC_GROUPNAME" /var/log/lighttpd
|
touch /var/log/lighttpd/error.log && chown -R "$BACKUPPC_USERNAME":"$BACKUPPC_GROUPNAME" /var/log/lighttpd
|
||||||
|
|
||||||
# Configure standard mail delivery parameters (may be overriden by backuppc user-wide config)
|
# Configure standard mail delivery parameters (may be overriden by backuppc user-wide config)
|
||||||
|
if [ ! -f /etc/msmtprc ]; then
|
||||||
echo "account default" > /etc/msmtprc
|
echo "account default" > /etc/msmtprc
|
||||||
echo "logfile /var/log/msmtp.log" >> /etc/msmtprc
|
echo "logfile /var/log/msmtp.log" >> /etc/msmtprc
|
||||||
echo "host ${SMTP_HOST:-mail.example.org}" >> /etc/msmtprc
|
echo "host ${SMTP_HOST:-mail.example.org}" >> /etc/msmtprc
|
||||||
@ -114,6 +115,7 @@ if [ -f /firstrun ]; then
|
|||||||
fi
|
fi
|
||||||
touch /var/log/msmtp.log
|
touch /var/log/msmtp.log
|
||||||
chown "${BACKUPPC_USERNAME}:${BACKUPPC_GROUPNAME}" /var/log/msmtp.log
|
chown "${BACKUPPC_USERNAME}:${BACKUPPC_GROUPNAME}" /var/log/msmtp.log
|
||||||
|
fi
|
||||||
|
|
||||||
# Clean
|
# Clean
|
||||||
rm -rf "/root/BackupPC-$BACKUPPC_VERSION.tar.gz" "/root/BackupPC-$BACKUPPC_VERSION" /firstrun
|
rm -rf "/root/BackupPC-$BACKUPPC_VERSION.tar.gz" "/root/BackupPC-$BACKUPPC_VERSION" /firstrun
|
||||||
|
@ -38,6 +38,7 @@ def main():
|
|||||||
"## master - CURRENT\n",
|
"## master - CURRENT\n",
|
||||||
"""\
|
"""\
|
||||||
## master - CURRENT
|
## master - CURRENT
|
||||||
|
|
||||||
## {0} - {1}
|
## {0} - {1}
|
||||||
""".format(
|
""".format(
|
||||||
new_version, today.strftime("%d/%m/%Y")
|
new_version, today.strftime("%d/%m/%Y")
|
||||||
|
Loading…
Reference in New Issue
Block a user