Connect. Communicate. Collaborate. Securely.

Home » Kerio User Forums » Kerio Operator » Template Overrides - Documentation? Help?
  •  
88fingerslukee

Messages: 177
Karma: 0
Send a private message to this user
I have no idea what do here.

Can I create an override per extension?
Can I create an override per type of snom phone?
How do I add this value
<position_of_vkey_in_edit_number perm="PERMISSIONFLAG">VALIDVALUE</position_of_vkey_in_edit_number>

to the template?
  •  
Filip Jenicek (Kerio)

Messages: 1094
Karma: 80
Send a private message to this user
Hi,

it is a bit complicated. Template overrides were developed to allow you to change default values in the provisioning template. For example when you want to change the phones' language. Same file is usually used for a group of phones, for example for all snom phones or all cisco spa phones.

However, if you have some basic programming skills, know a little bit of php, you can achieve almost anything.

Our documentation team is currently preparing a KB article to describe how to use this feature.


Due to lack of time I'm not able to support you on this one, but I can give you a few clues for easier start.

Lines beginning with <_at_> contain regular php code which is executed when the template is sent to the phone. So you can do things like:
@ if ($IDENT === 'snom720') {
language: Deutsch
@ }

This will switch the snom 720 phones' language to german.

To find out what the variable $IDENT can contain, you can temporary add line:
@ var_dump($PHONE_TYPES);

To view the result, right click on a snom phone and select "Download configuration". A file from the archive will contain the dumped variable.

To differentiate between the phones, you can use variables such as $PHONE_IP or the $LINES array. To change a specific phone, one can do:
@ if ($PHONE_IP === '192.168.12.11') {
language: Deutsch
@ }

Note that in this case you can not verify the functionality by downloading the file in the administration, because the PHONE_IP will not match.

Another example migh be:
@ if (isset($LINES[0]) && $LINES[0]['TELNUM'] === '21') {
language: Deutsch
@ }


A more detailed description of the provisioning system can be found in the archives, the last version is available here. The document focuses on how to write a custom provisioning module. Nevertheless, file refguide.pdf can come quite handy when it comes to template overrides.

Filip
  •  
nhoague

Messages: 853
Karma: 18
Send a private message to this user
Hello,

So with this new provisioning model, are we unable to write custom configs for unique phones?

i.e. The boss wants his phone configured a certain way, while all other 30 phones can be standard. I used to just modify the config and upload to /var/tftp/ but now that doesnt work.

Whats the protocol now?

Thanks!
  •  
nhoague

Messages: 853
Karma: 18
Send a private message to this user
Also I've noticed now that if / when I make a change to the template override, Operator doesn't show me which phones have an out of date configuration?
  •  
Filip Jenicek (Kerio)

Messages: 1094
Karma: 80
Send a private message to this user
Hi,

it is still possible to use /var/tftp. The only difference is, that some paths might have changed a bit. Please download a phone's configuration from the Phones screen and observe paths in the zip archive. Then upload the file back to /var/tftp/.

For example, a Cisco 514 phone will fetch the configuration from /var/tftp/Cisco/SPA514G/70ca9b9f2aac.cfg


Changing a template override should trigger a notification about an outdated configuration. I will file a bug report in our internal systems.

Thank you,
Filip
  •  
nhoague

Messages: 853
Karma: 18
Send a private message to this user
Hmm this just doesnt seem to work. I download the original config, make a change to it, upload to the correct location, and then factory reset the phone and it pulls the config from the template override, not the custom config I want it to pull.

Bug? Does this not work when we are using template overrides?
  •  
Filip Jenicek (Kerio)

Messages: 1094
Karma: 80
Send a private message to this user
Could you be more specific? Give me an example, please.

Btw, you can access provisioning files using one of the supported protocols (http, ftp, tftp). You can, for example, open http://IP/Cisco/SPA514G/70ca9b9f2aac.cfg and verify the contents.
  •  
nhoague

Messages: 853
Karma: 18
Send a private message to this user
Ok this helps me to understand that the file I have uploaded to the Operator is definitely not the one I want!

So, now how to fix this ... hmm.

I uploaded to /var/tftp/Cisco/SPA504G/1cdf0f4a3e9a.cfg and this is not what I get from http://{IP}/Cisco/SPA504G/1cdf0f4a3e9a.cfg

Ideas?
  •  
Filip Jenicek (Kerio)

Messages: 1094
Karma: 80
Send a private message to this user
Linux paths are case sensitive so are you sure that you have it correct?

I tried
root@Operator:/var/tftp# mkdir -p /var/tftp/Cisco/SPA504G/
root<_at_>Operator:/var/tftp# echo "test" >/var/tftp/Cisco/SPA504G/1cdf0f4a3e9a.cfg
root<_at_>Operator:/var/tftp# wget ftp://localhost/Cisco/SPA504G/1cdf0f4a3e9a.cfg -O - -q
test


Also check that you haven't disabled the /var/tftp provisioning module (it is the first one in the list).
  •  
nhoague

Messages: 853
Karma: 18
Send a private message to this user
Ah ha! It was the /var/tftp provisioning module. Thats it, thanks!!!
Previous Topic: Transferring calls
Next Topic: Phone choice
Goto Forum:
  


Disclaimer:
Kerio discussion forums are intended for open communication between forum members and may contain information and material posted by members which may be useful in learning about Kerio products. The discussion forums are not intended to provide technical support for any specific product. Any information implied or expressed in the discussion forums is that of the posting member. Kerio is in no way responsible for the information posted in the forums, or its accuracy. Kerio employees may participate in the discussions, but their postings do not represent an offical position of the company on any issues raised or discussed. Kerio reserves the right to monitor and maintain the forums to promote free and accurate exchange of information.

Current Time: Sat Aug 19 11:17:53 CEST 2017

Total time taken to generate the page: 0.00500 seconds
.:: Contact :: Home ::.
Powered by: FUDforum 3.0.4.