[Asterisk-code-review] Core: Add support for systemd socket activation. (asterisk[master])

George Joseph asteriskteam at digium.com
Mon Jun 19 10:49:28 CDT 2017


George Joseph has posted comments on this change. ( https://gerrit.asterisk.org/5877 )

Change subject: Core: Add support for systemd socket activation.
......................................................................


Patch Set 3:

(2 comments)

> (1 comment)
 > 
 > > (1 comment)
 > >
 > > What's the use case?
 > 
 > This is mainly meant for the administrative interfaces: AMI, CLI,
 > and HTTP for rest api.  Obviously it would be up to a local admin
 > to decide if they wanted any of the individual components to cause
 > Asterisk startup.  For my own use case I intend to enable AMI only
 > so the unprivileged service running on localhost can force Asterisk
 > to start.

Ah, gotcha.  I'd add the "start via ami or ari" case to the readme.

 > 
 > As for the sip-tcp / sip-tls listeners, I'm not sure of a
 > reasonable use case for enabling socket activation on those.  I
 > documented them since they use ast_tcptls_server_start and thus can
 > use socket activation.  If wanted I can remove the socket files for
 > chan_sip to show that they are not the intended use case?

I'd remove the sip references.  I can't think of a use case where someone would want asterisk to automatically start on a sip tcp or tls attempt.  Might be a security risk.

https://gerrit.asterisk.org/#/c/5877/3/contrib/systemd/asterisk-http.socket
File contrib/systemd/asterisk-http.socket:

https://gerrit.asterisk.org/#/c/5877/3/contrib/systemd/asterisk-http.socket@1
PS3, Line 1: [Unit]
> This was the first one I tested, it worked for me.  Can you
 > double-check your settings between asterisk-http.socket and
 > asterisk/http.conf?  The bind address needs to be an exact match.

Yeah, asterisk was listening on '[::]' but the unit was listening on '0.0.0.0'


https://gerrit.asterisk.org/#/c/5877/3/contrib/systemd/asterisk-http.socket@1
PS3, Line 1: [Unit]
> http doesn't seem to work.  asterisk starts but the socket doesn't
 > seem to be passed through to asterisk.



-- 
To view, visit https://gerrit.asterisk.org/5877
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Id814ee6a892f4b80d018365c8ad8d89063474f4d
Gerrit-Change-Number: 5877
Gerrit-PatchSet: 3
Gerrit-Owner: Corey Farrell <git at cfware.com>
Gerrit-Reviewer: Corey Farrell <git at cfware.com>
Gerrit-Reviewer: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Jenkins2
Gerrit-Comment-Date: Mon, 19 Jun 2017 15:49:28 +0000
Gerrit-HasComments: Yes
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20170619/63433454/attachment.html>


More information about the asterisk-code-review mailing list