Jump to content

Solusvm Module In Blesta 3.5: Looks For Iso Templates, Not Kvm Templates


André P.

Recommended Posts

Hi,

 

I want to create a new VPS package, so I choose SolusVM, select KVM as hypervisor and then I want to select a template. Well, I guess since 3.5 (upgraded from 3.4.4 and cannot remember this behavior) I only see ISO files anymore. When I select "let users choose a template" the users also only see the ISO templates.

 

I already deleted the media groups and also removed the ISO files. But then the drop down menu for "templates" is just empty. It looks for ISOs, not KVM templates.

 

Regards,

André

 

Edit: I guess you wanted to switch from displaying the file name of the KVM templates to displaying their actual "display name" as defined inside SolusVM. And then accidentally used the ISO display names. :-)

Link to comment
Share on other sites

Everything in its latest version, module logs:

status => successnplans => vserver l,vserver m,vserver xl
status => successnnodes => Jupiter
status => successnmsg => --none--
status => successntemplates => --none--,ubuntu-15.04-server-mini-amd64|Ubuntu 15.04 Server amd64 minimal,debian-8.1.0-amd64-netinst|Debian 8.1.0 amd64 netinstall,ubuntu-14.04-server-mini-amd64|Ubuntu 14.04 Server amd64 minimal,CentOS-6.6-x86_64-netinstall|CentOS 6.6 x86_64 netinstall,CentOS-7-x86_64-NetInstall-1503|CentOS 7.0 x86_64 netinstall

Above are all just ISOs.

 

Edit: I can give you access to the machines if that helps.

 

Edit2: Wow, I actually fixed this myself. :P 

 

solusvm.php, starting from line 2498:

                // Return the templates
                if ($response && $response->status == "success") {
                        // Fetch the templates
                        $templates = $this->csvToArray($response->templates);
                        $formatted_templates = array();
                        foreach ($templates as $template) {
                                // Skip the none template

I changed "$response->templates" on line 2500 (above in line 4) to "templateskvm".

One could add a check for "$type" and if it is !kvm to use "templates" then. Above fix works for me as I do not have any other templates than KVM.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...