How to serve multi-tenant service

Hi,
It is possible to serve on Asterisk multi-tenant service? If yes, how to do that or what I need to do this.

Yes. You different contexts for each tenant.

Ok, but how to create account (let suppose) for user extension 100 for multiple tenant? Using domains, prefix, sufix ?

Best practice is not to use the extension number as the device name, but if you must, one way would be include the customer number in the device name.

Also this question assumes a particular way of connecting the phones. It would have been meaningless if you had been using analogue phones. Please don’t assume that everyone is using chan_sip.

1 Like

So, you suggest to use something like [id_customer-100], am i right? And then make internal context

[internal]
exten => _XXX,1,Dial(SIP/id_customer${EXTEN})

I think to made only SIP platform without any other tech

The security advice is to use the MAC of the device, but what you show is probably the best way if you want to derive the device name from its primary extension number.

We use something like:

exten => _XXX,1,Dial(SIP/${EXTEN})-${TENANT})

where TENANT gets set in the inbound or outbound contexts for the tenant

1 Like