Iscriviti   Guestbook   Immagini   Forum   Download   Mappa   2659 utenti on line 
Italiano
MENU
CONFIGURAZIONI
RISORSE
INFO
Login

DOWNLOAD
Device
Suggerimenti

 
Asterisk Extension MySQL

There is a script in contrib/scripts called:
retrieve_extensions_from_mysql.pl

This can be used to write a file to be used to write out extensions.conf
- alternatively it can be used to create a subset which is #included into the main file

Create database:
CREATE TABLE extensions (
      context CHAR(20) DEFAULT 'default' NOT NULL,
      extension CHAR(20) NOT NULL,
      priority INT(2) DEFAULT '1' NOT NULL,
      application CHAR(20) NOT NULL,
      args CHAR(50),
      descr TEXT,
      flags INT(1) DEFAULT '0' NOT NULL,
      PRIMARY KEY(context, extension, priority)
);

CREATE TABLE globals (
      variable CHAR(20) NOT NULL,
      value CHAR(50) NOT NULL,
      PRIMARY KEY(variable, value)
);

If flags is 1 then this record is not included in the output extensions file

The username specified in the file only needs to have SELECT priviliges on this database.

Asterisk needs to be reloaded after running this script in order to see the changes activated.


 

Valid CSS!