mirror of
https://github.com/mail-in-a-box/mailinabox.git
synced 2024-11-22 02:17:26 +00:00
Remove owncloud log configuration from initial setup and only apply it during the configuration updates. This applies to both the timezone and the log format
This commit is contained in:
parent
d9ac321f25
commit
fb14e30feb
@ -92,7 +92,6 @@ if [ ! -f $STORAGE_ROOT/owncloud/owncloud.db ]; then
|
|||||||
mkdir -p $STORAGE_ROOT/owncloud
|
mkdir -p $STORAGE_ROOT/owncloud
|
||||||
|
|
||||||
# Create an initial configuration file.
|
# Create an initial configuration file.
|
||||||
TIMEZONE=$(cat /etc/timezone)
|
|
||||||
instanceid=oc$(echo $PRIMARY_HOSTNAME | sha1sum | fold -w 10 | head -n 1)
|
instanceid=oc$(echo $PRIMARY_HOSTNAME | sha1sum | fold -w 10 | head -n 1)
|
||||||
cat > $STORAGE_ROOT/owncloud/config.php <<EOF;
|
cat > $STORAGE_ROOT/owncloud/config.php <<EOF;
|
||||||
<?php
|
<?php
|
||||||
@ -125,8 +124,6 @@ if [ ! -f $STORAGE_ROOT/owncloud/owncloud.db ]; then
|
|||||||
'mail_smtppassword' => '',
|
'mail_smtppassword' => '',
|
||||||
'mail_from_address' => 'owncloud',
|
'mail_from_address' => 'owncloud',
|
||||||
'mail_domain' => '$PRIMARY_HOSTNAME',
|
'mail_domain' => '$PRIMARY_HOSTNAME',
|
||||||
'logtimezone' => '$TIMEZONE',
|
|
||||||
'logdateformat' => 'Y-m-d H:i:s',
|
|
||||||
);
|
);
|
||||||
?>
|
?>
|
||||||
EOF
|
EOF
|
||||||
@ -166,6 +163,7 @@ fi
|
|||||||
# * Some settings weren't included in previous versions of Mail-in-a-Box.
|
# * Some settings weren't included in previous versions of Mail-in-a-Box.
|
||||||
# * We need to set the timezone to the system timezone to allow fail2ban to ban
|
# * We need to set the timezone to the system timezone to allow fail2ban to ban
|
||||||
# users within the proper timeframe
|
# users within the proper timeframe
|
||||||
|
# * We need to set the logdateformat to something that will work correctly with fail2ban
|
||||||
# Use PHP to read the settings file, modify it, and write out the new settings array.
|
# Use PHP to read the settings file, modify it, and write out the new settings array.
|
||||||
TIMEZONE=$(cat /etc/timezone)
|
TIMEZONE=$(cat /etc/timezone)
|
||||||
CONFIG_TEMP=$(/bin/mktemp)
|
CONFIG_TEMP=$(/bin/mktemp)
|
||||||
|
Loading…
Reference in New Issue
Block a user