Provisioning Module 500 Error

Has anyone see this before? If so any advice would be appreciated.
This is a fresh install of VPBX 4.5
When I update a template or add a device I get this error. I have done the follow things to resolve this:

  1. Removed the template and created a new one with all default settings.
  2. Tried different phones.
  3. Uninstalled the provisioning add on and reinstalled it again.
  4. Ran the clean up CLI commands.

What model and brand are you using?

Yealink T54W & Yealink T48G

I dont believe its anything to do with the phones themselves, because we have another Vital PBX 4.5 server that has those same phone models and doesn’t present these errors.

Miguel - Any thoughts on how to resolve this issue?

Did you edit the template? It seems to be an issue in a foreach loop. Compare the two templates for your working system and this one to find the issue

UPDATE
I first said that this was on one server and not the other. But this appears on our other server also. Both are running Debian 12/VitalPBX 4.5

Server 1 was on 4.3 and debian 11. I spun up a new server with Debian 12 and restored the backup from 4.3 to 4.5

Server 2 was a fresh install on Debian 12 with 4.5

Both are doing this when you edit an existing template or try and add a new phone.

Anyone that has upgraded from 4.3 to 4.5 if you haven’t tried to add a new phone you should try that. I will be opening a ticket with support in a few minutes.

Here are the lines near the error:

Seems like an issue with the template and the expansion module keys. Is the provisioning module currently showing you the expansion module tab?

From the web interface go into the template file and remove the following:

@foreach($expansionModuleKeys as $expansionModule)
@foreach($expansionModule as $key)
expansion_module.{{ $loop->parent->iteration }}.key.{{ $loop->iteration }}.type = {{ $key['type'] ?? null }}
expansion_module.{{ $loop->parent->iteration }}.key.{{ $loop->iteration }}.label = {{ $key['description'] ?? null }}
expansion_module.{{ $loop->parent->iteration }}.key.{{ $loop->iteration }}.value = {{ $key['value'] ?? null }}
expansion_module.{{ $loop->parent->iteration }}.key.{{ $loop->iteration }}.line = {{ $key['line'] ?? 1 }}
expansion_module.{{ $loop->parent->iteration }}.key.{{ $loop->iteration }}.extension = {{ $key['extension'] ?? null }}
expansion_module.{{ $loop->parent->iteration }}.key.{{ $loop->iteration }}.xml_phonebook =
@endforeach
@endforeach

For now until there is a fix, that should allow you to be able to save the templates and add phones.

1 Like

No, the expansion module tab is missing from the provisioning template. Great catch!!
I’m going to move back to 4.3 in the AM.

We found the issue and the patch will be available in the next VitalPBX 4.5 update!

Any idea on when the update will come out?

I would say, next week probably!

1 Like