setting programs to run in foreground
This commit is contained in:
parent
1858f8c0ce
commit
663c180fc3
|
@ -1123,8 +1123,9 @@ function start_daemons() {
|
||||||
}
|
}
|
||||||
|
|
||||||
function _start_daemons_cron() {
|
function _start_daemons_cron() {
|
||||||
notify 'task' 'Starting cron' 'n'
|
notify 'task' 'Skipping starting cron\n' 'n'
|
||||||
supervisorctl start cron
|
# cron starts automatically. I don't think this is necessary.
|
||||||
|
#supervisorctl start cron
|
||||||
}
|
}
|
||||||
|
|
||||||
function _start_daemons_rsyslog() {
|
function _start_daemons_rsyslog() {
|
||||||
|
@ -1134,7 +1135,7 @@ function _start_daemons_rsyslog() {
|
||||||
|
|
||||||
function _start_daemons_saslauthd() {
|
function _start_daemons_saslauthd() {
|
||||||
notify 'task' 'Starting saslauthd' 'n'
|
notify 'task' 'Starting saslauthd' 'n'
|
||||||
supervisorctl start saslauthd
|
display_startup_daemon "/etc/init.d/saslauthd start"
|
||||||
}
|
}
|
||||||
|
|
||||||
function _start_daemons_fail2ban() {
|
function _start_daemons_fail2ban() {
|
||||||
|
@ -1159,7 +1160,7 @@ function _start_daemons_opendmarc() {
|
||||||
|
|
||||||
function _start_daemons_postfix() {
|
function _start_daemons_postfix() {
|
||||||
notify 'task' 'Starting postfix' 'n'
|
notify 'task' 'Starting postfix' 'n'
|
||||||
supervisorctl start postfix
|
display_startup_daemon "/etc/init.d/postfix start"
|
||||||
}
|
}
|
||||||
|
|
||||||
function _start_daemons_dovecot() {
|
function _start_daemons_dovecot() {
|
||||||
|
@ -1170,7 +1171,7 @@ function _start_daemons_dovecot() {
|
||||||
if [ "$ENABLE_POP3" = 1 ]; then
|
if [ "$ENABLE_POP3" = 1 ]; then
|
||||||
notify 'task' 'Starting pop3 services' 'n'
|
notify 'task' 'Starting pop3 services' 'n'
|
||||||
mv /etc/dovecot/protocols.d/pop3d.protocol.disab /etc/dovecot/protocols.d/pop3d.protocol
|
mv /etc/dovecot/protocols.d/pop3d.protocol.disab /etc/dovecot/protocols.d/pop3d.protocol
|
||||||
display_startup_daemon "/usr/sbin/dovecot reload"
|
/usr/sbin/dovecot reload
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -f /tmp/docker-mailserver/dovecot.cf ]; then
|
if [ -f /tmp/docker-mailserver/dovecot.cf ]; then
|
||||||
|
@ -1196,7 +1197,7 @@ function _start_daemons_filebeat() {
|
||||||
function _start_daemons_fetchmail() {
|
function _start_daemons_fetchmail() {
|
||||||
notify 'task' 'Starting fetchmail' 'n'
|
notify 'task' 'Starting fetchmail' 'n'
|
||||||
/usr/local/bin/setup-fetchmail
|
/usr/local/bin/setup-fetchmail
|
||||||
supervisorctl start fetchmail
|
display_startup_daemon "/etc/init.d/fetchmail start"
|
||||||
}
|
}
|
||||||
|
|
||||||
function _start_daemons_clamav() {
|
function _start_daemons_clamav() {
|
||||||
|
@ -1248,7 +1249,7 @@ notify 'taskgrp' "#"
|
||||||
notify 'taskgrp' "#"
|
notify 'taskgrp' "#"
|
||||||
notify 'taskgrp' ""
|
notify 'taskgrp' ""
|
||||||
|
|
||||||
supervisord
|
supervisord -c /etc/supervisor/conf.d/supervisor-app.conf
|
||||||
|
|
||||||
register_functions
|
register_functions
|
||||||
|
|
||||||
|
|
|
@ -1,83 +1,81 @@
|
||||||
# each program entry below is a separate terminal command.
|
# each program entry below is a separate terminal command.
|
||||||
# Each command is expected to run in the foreground and stay running.
|
# Each command MUST run in the foreground and stay running.
|
||||||
# If the command ever exits, the supervisor daemon will automatically run it again.
|
# If the command ever exits, the supervisor daemon will automatically run it again.
|
||||||
# Programs can be controlled like this: 'supervisorctl start fail2ban' 'supervisorctl stop fail2ban'
|
# Programs can be controlled like this: 'supervisorctl start fail2ban' 'supervisorctl stop fail2ban'
|
||||||
# supervisor writes program statuses in /var/log/supervisor
|
# supervisor writes program statuses in /var/log/supervisor
|
||||||
|
|
||||||
[program:cron]
|
|
||||||
startsecs=0
|
|
||||||
autostart=false
|
|
||||||
autorestart=true
|
|
||||||
command = /usr/sbin/cron
|
|
||||||
|
|
||||||
[program:rsyslog]
|
[program:rsyslog]
|
||||||
startsecs=0
|
startsecs=0
|
||||||
autostart=false
|
autostart=false
|
||||||
autorestart=true
|
autorestart=true
|
||||||
command = /etc/init.d/rsyslog start
|
command = /usr/sbin/rsyslogd -n
|
||||||
|
|
||||||
[program:saslauthd]
|
|
||||||
startsecs=0
|
# Couldn't figure out how to run this in the foreground. We'll start it without supervisor.
|
||||||
autostart=false
|
#[program:saslauthd]
|
||||||
autorestart=true
|
#startsecs=0
|
||||||
command = /etc/init.d/saslauthd start
|
#autostart=false
|
||||||
|
#autorestart=true
|
||||||
|
#command = /etc/init.d/saslauthd start
|
||||||
|
|
||||||
[program:fail2ban]
|
[program:fail2ban]
|
||||||
startsecs=0
|
startsecs=0
|
||||||
autostart=false
|
autostart=false
|
||||||
autorestart=true
|
autorestart=true
|
||||||
command = /etc/init.d/fail2ban start
|
command = /usr/bin/fail2ban-server -f
|
||||||
|
|
||||||
[program:opendkim]
|
[program:opendkim]
|
||||||
startsecs=0
|
startsecs=0
|
||||||
autostart=false
|
autostart=false
|
||||||
autorestart=true
|
autorestart=true
|
||||||
command = /etc/init.d/opendkim start
|
command = /usr/sbin/opendkim -f
|
||||||
|
|
||||||
[program:opendmarc]
|
[program:opendmarc]
|
||||||
startsecs=0
|
startsecs=0
|
||||||
autostart=false
|
autostart=false
|
||||||
autorestart=true
|
autorestart=true
|
||||||
command = /etc/init.d/opendmarc start
|
command = /usr/sbin/opendmarc -f -p local:/var/run/opendmarc/opendmarc.sock
|
||||||
|
|
||||||
[program:postfix]
|
# Couldn't figure out how to run this in the foreground. We'll start it without supervisor.
|
||||||
startsecs=0
|
#[program:postfix]
|
||||||
autostart=false
|
#startsecs=0
|
||||||
autorestart=true
|
#autostart=false
|
||||||
command = /etc/init.d/postfix start
|
#autorestart=true
|
||||||
|
#command = /etc/init.d/postfix start
|
||||||
|
|
||||||
[program:dovecot]
|
[program:dovecot]
|
||||||
startsecs=0
|
startsecs=0
|
||||||
autostart=false
|
autostart=false
|
||||||
autorestart=true
|
autorestart=true
|
||||||
command = /usr/sbin/dovecot -c /etc/dovecot/dovecot.conf
|
command = /usr/sbin/dovecot -F -c /etc/dovecot/dovecot.conf
|
||||||
|
|
||||||
[program:filebeat]
|
[program:filebeat]
|
||||||
startsecs=0
|
startsecs=0
|
||||||
autostart=false
|
autostart=false
|
||||||
autorestart=true
|
autorestart=true
|
||||||
command = /etc/init.d/filebeat start
|
command = /usr/bin/filebeat -c /etc/filebeat/filebeat.yml
|
||||||
|
|
||||||
[program:fetchmail]
|
# Couldn't figure out how to run this in the foreground. We'll start it without supervisor.
|
||||||
startsecs=0
|
#[program:fetchmail]
|
||||||
autostart=false
|
#startsecs=0
|
||||||
autorestart=true
|
#autostart=false
|
||||||
command = /etc/init.d/fetchmail start
|
#autorestart=true
|
||||||
|
#command = /usr/bin/fetchmail
|
||||||
|
|
||||||
[program:clamav]
|
[program:clamav]
|
||||||
startsecs=0
|
startsecs=0
|
||||||
autostart=false
|
autostart=false
|
||||||
autorestart=true
|
autorestart=true
|
||||||
command = /etc/init.d/clamav-daemon start
|
command = /usr/sbin/clamd -c /etc/clamav/clamd.conf
|
||||||
|
|
||||||
[program:postgrey]
|
[program:postgrey]
|
||||||
startsecs=0
|
startsecs=0
|
||||||
autostart=false
|
autostart=false
|
||||||
autorestart=true
|
autorestart=true
|
||||||
command = /etc/init.d/postgrey start
|
command = /usr/sbin/postgrey --inet=127.0.0.1:10023
|
||||||
|
|
||||||
[program:amavis]
|
[program:amavis]
|
||||||
startsecs=0
|
startsecs=0
|
||||||
autostart=false
|
autostart=false
|
||||||
autorestart=true
|
autorestart=true
|
||||||
command = /etc/init.d/amavis start
|
command = /usr/sbin/amavisd-new foreground
|
||||||
|
|
Loading…
Reference in New Issue