Here is a module that will assist in Auto Provisioning Polycom Phones
You add a MAC and map it to a device on "Add phone"
It will download 000000000000.cfg.template and phone1.cfg.template from your ftp server and replace varibles then upload them to the ftp server as (mac).cfg and (mac)-phone1.cfg
The varibles are replaced with values from the sip table e.g. account in the sip table will replace any occerance of %ACCOUNT% in the template files, %MAC% is also replaced with the mac address of the phone.
currently the ftp host, username, and password are hard coded.
Under settings there is:
"Update All" - which will recreate the config files.
and
"Detect and map phones" - which will search for polycom MAC addresses and allow you to quickly assing them (uses the nmap scaning on DevicesTakeTwo )
This is my first module and the coding is a little bit of a mess but here you go.