forked from mirrors/kore
move kore_server_sslstart() into main process, workers will inherit.
This commit is contained in:
parent
72e09424af
commit
32a2035ce9
|
@ -4,11 +4,9 @@
|
|||
bind 10.211.55.3 443
|
||||
|
||||
# The path worker processes will chroot too after starting.
|
||||
# (Make sure your X.509 certificates are available in this path).
|
||||
chroot /home/joris/src/kore
|
||||
|
||||
# Worker processes will run as the specified user.
|
||||
# (Make sure this user has correct permissions on your X.509 certificates).
|
||||
runas joris
|
||||
|
||||
# Set workers to the amount of CPU's available in your system,
|
||||
|
|
|
@ -146,6 +146,8 @@ main(int argc, char *argv[])
|
|||
cpu_count = 1;
|
||||
}
|
||||
|
||||
if (!kore_server_sslstart())
|
||||
fatal("cannot initiate SSL");
|
||||
if (!kore_server_bind(&server, server_ip, server_port))
|
||||
fatal("cannot bind to %s:%d", server_ip, server_port);
|
||||
if (daemon(1, 1) == -1)
|
||||
|
@ -593,9 +595,6 @@ kore_worker_entry(struct kore_worker *kw)
|
|||
}
|
||||
|
||||
mypid = kw->pid;
|
||||
|
||||
if (!kore_server_sslstart())
|
||||
fatal("cannot initiate SSL");
|
||||
if ((efd = epoll_create(1000)) == -1)
|
||||
fatal("epoll_create(): %s", errno_s);
|
||||
|
||||
|
|
Loading…
Reference in New Issue