aboutsummaryrefslogtreecommitdiffstats
path: root/configs/phoneprov.conf.sample
diff options
context:
space:
mode:
authortwilson <twilson@f38db490-d61c-443f-a65b-d21fe96a405b>2008-01-09 21:37:26 +0000
committertwilson <twilson@f38db490-d61c-443f-a65b-d21fe96a405b>2008-01-09 21:37:26 +0000
commit11f6af8c7b1aa84f602cec7258bdb6ef8d29851d (patch)
treea60d56d18dfd1b80f57e5bc99e3b1fc1c2999bfe /configs/phoneprov.conf.sample
parent34c07ddcafffa916f65e5f4b0e356e7b29e47b2d (diff)
Added a new module, res_phoneprov, which allows auto-provisioning of phones
based on configuration templates that use Asterisk dialplan function and variable substitution. It should be possible to create phone profiles and templates that work for the majority of phones provisioned over http. It is currently only intended to provision a single user account per phone. An example profile and set of templates for Polycom phones is provided. NOTE: Polycom firmware is not included, but should be placed in AST_DATA_DIR/phoneprov/configs to match up with the included templates. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@97634 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'configs/phoneprov.conf.sample')
-rw-r--r--configs/phoneprov.conf.sample55
1 files changed, 55 insertions, 0 deletions
diff --git a/configs/phoneprov.conf.sample b/configs/phoneprov.conf.sample
new file mode 100644
index 000000000..3b82490c1
--- /dev/null
+++ b/configs/phoneprov.conf.sample
@@ -0,0 +1,55 @@
+[general]
+;serveraddr=192.168.1.1 ; Address to send to the phone to use as server address.
+serveriface=eth0 ; Same as above, except an ethernet interface.
+ ; Useful for when the interface uses DHCP.
+ ; There is no default for either of the above, and only one should be set.
+serverport=5060 ; Port to send to the phone to use as server port. Default is 5060.
+default_profile=polycom ; The default profile to use if none specified in users.conf
+
+; You can define profiles for different phones specifying what files to register
+; with the provisioning server. You can define either static files, or dynamically
+; generated files that can have dynamic names and point to templates that variables
+; can be substituted into. You can also set arbitrary variables for the profiles
+; templates to have access to. Example:
+
+;[example]
+;mime_type => application/octet-stream
+;static_file => example/firmware
+;static_file => example/default.cfg,text/xml
+;${TOUPPER(${MAC})}.cfg => templates/example-mac.cfg
+;setvar => DB_CIDNAME=${ODBC_CID_NAME_LOOKUP(${USERNAME})}
+
+; Dynamically generated files have a filename registered with variable substitution
+; with variables obtained while reading users.conf.
+
+; Built in variables and the options in users.conf that they come from
+; MAC (macaddress)
+; USERNAME (username)
+; DISPLAY_NAME (fullname)
+; SECRET (secret)
+; LABEL (label)
+; CALLERID (cid_number)
+; VOCIEMAIL_EXTEN (vmexten)
+; EXTENSION_LENGTH (localextenlength)
+
+; Built-in variables and the options in phoneprov.conf that they come from
+; SERVER (server)
+; SERVER_PORT (serverport)
+
+[polycom]
+staticdir => configs/ ; Sub directory of AST_DATA_DIR/phoneprov that static files reside
+ ; in. This allows a request to /phoneprov/sip.cfg to pull the file
+ ; from /phoneprov/configs/sip.cfg
+mime_type => text/xml ; Default mime type to use if one isn't specified or the
+ ; extension isn't recognized
+static_file => bootrom.ld,application/octet-stream ; Static files the phone will download
+static_file => bootrom.ver,plain/text ; static_file => filename,mime-type
+static_file => sip.ld,application/octet-stream
+static_file => sip.ver,plain/text
+static_file => sip.cfg
+static_file => custom.cfg
+${TOLOWER(${MAC})}.cfg => 000000000000.cfg ; Dynamically generated files.
+${TOLOWER(${MAC})}-phone.cfg => 000000000000-phone.cfg ; (relative to AST_DATA_DIR/phoneprov)
+config/${TOLOWER(${MAC})} => polycom.xml ; Dynamic Filename => template file
+${TOLOWER(${MAC})}-directory.xml => 000000000000-directory.xml
+setvar => CUSTOM_CONFIG=/var/lib/asterisk/phoneprov/configs/custom.cfg ; Custom variable