Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Ian Eiloart
Sympl
Commits
489460f0
Commit
489460f0
authored
Jul 06, 2019
by
Paul Cammish
Browse files
Fixed race condition bug
parent
6742f102
Changes
2
Hide whitespace changes
Inline
Side-by-side
mail/sbin/sympl-mail-dovecot-sni
View file @
489460f0
...
...
@@ -12,7 +12,7 @@ if [ ! -L /srv/*/config/ssl/current ]; then
cd
/etc/dovecot
sudo
/usr/bin/make
test
sudo
/usr/bin/make
>
/dev/null
sudo
/usr/sbin/service dovecot reload
sudo
/usr/sbin/service dovecot reload
>
/dev/null 2>&1 |
true
fi
exit
0
else
...
...
@@ -50,7 +50,7 @@ done >> /dev/shm/sympl-mail-dovecot-sni.config
# Compare it with what's there already.
if
[
-f
"/etc/dovecot/sympl.d/10-main/60-sni"
]
;
then
if
diff /dev/shm/sympl-mail-dovecot-sni.config /etc/dovecot/sympl.d/10-main/60-sni
>
/dev/null
;
then
# Config has
no
t changed, exit
ing
.
# Config has
n
t changed,
so just
exit.
exit
0
fi
fi
...
...
@@ -63,7 +63,7 @@ if [ -f /etc/dovecot/Makefile ]; then
cd
/etc/dovecot
sudo
/usr/bin/make
test
sudo
/usr/bin/make
>
/dev/null
sudo
/usr/sbin/service dovecot reload
sudo
/usr/sbin/service dovecot reload
>
/dev/null 2>&1 |
true
fi
if
[
-f
/dev/shm/sympl-mail-dovecot-sni.data
]
;
then
rm
/dev/shm/sympl-mail-dovecot-sni.data
;
fi
...
...
mail/sympl/ssl-hooks.d/sympl-mail
View file @
489460f0
#!/bin/bash
-eu
#!/bin/bash
if
!
[
"
$1
"
=
"live-update"
]
;
then
echo
"I:
$0
: Ignoring unknown hook action
$1
"
if
!
[
"
x
$1
"
=
"
x
live-update"
]
;
then
echo
"I:
$0
: Ignoring unknown hook action
'
$1
'
"
exit
0
fi
#
# Rebuild Dovecot SNI Certificates and reload
on cert change
.
# Rebuild Dovecot SNI Certificates and reload
config
.
#
/usr/sbin/sympl-mail-dovecot-sni
/usr/sbin/service dovecot reload
\ No newline at end of file
/usr/sbin/service dovecot reload
>
/dev/null 2>&1 |
true
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment