SOLVED Yealink Provisioning Files and FusionPBX Variables

Status
Not open for further replies.

gunemalli

New Member
Dec 18, 2018
24
3
3
Hi All,

I'm having some issues with generating provisioning files with my FusionPBX installation. The default setup works, however I need to add a few lines to the templates to meet a customer requirement.

Yealink has a way of uploading and storing user configured settings using the MAC-local.cfg file. Adding the necessary config lines to the relevant templates works fine and the actual upload/download function also works fine.

I created a variable named yealink_autop_sync_local with type text and set the value to 0 on the Default Settings section and to 1 under the relevant domain.

Next I added the following code bit to the Yealink template files.

Code:
{if $yealink_autop_sync_local == 1}
static.auto_provision.custom.sync = 1
static.auto_provision.custom.protect = 1
static.auto_provision.custom.sync.path = ftp://ftp.domain.tld/upload
{else}
static.auto_provision.custom.sync = 0
static.auto_provision.custom.protect = 0
{/if}

Now the bit that doesn't work for some reason. Irrespective of the value I set for the yealink_autop_sync_local at the Advanced -> Default Settings or at domain level, when generating the config file FusionPBX shows the value as "True". However, if I set the same setting under Devices -> MAC -> Settings, it works correctly.

I've even tried setting the variable type to text, boolean and numeric and still the results are the same.

Fusion PBX 4.4.2
Debian 8.8
PHP 7.1.22

It would be a big help if someone point me to the correct path to get this fixed.

Kind Regards,
Asanka
 

JamesBorne

Active Member
Jan 24, 2019
294
57
28
Australia
Is your variable stored in Advanced > Default Settings with a category of 'provision' and the subcategory of 'yealink_autop_sync_local'?
Did you hit 'reload' in the top right of Advanced > Default Settings after creating the new variable?
 

gunemalli

New Member
Dec 18, 2018
24
3
3
Hi James,

Yes I did. It wasn't working correctly the day I set it up, but now it's working as expected.

Thanks for you help
 
  • Like
Reactions: JamesBorne
Status
Not open for further replies.