bug exclusive ip-address in _getFreeDedicatedIp
Closed this issue · 3 comments
The dedicated reseller IPs included them in free IPS ... Attached patch for _getFreeDedicatedIp() function
Sorry for my English... xD
/lib/Plesk/Manager/V1632.php
After:
foreach($domains->xpath('//webspace/get/result') as $item) { try { $this->_checkErrors($item); foreach($item->data->hosting->vrt_hst->ip_address as $ip) { $ipListUse[(string)$ip] = (string)$ip; } } catch (Exception $e) { if (Plesk_Api::ERROR_OBJECT_NOT_FOUND != $e->getCode()) { throw $e; } } }
Included:
$resellers = Plesk_Registry::getInstance()->api->resellers_get(); if(isset($resellers) && !empty($resellers)) { foreach($resellers->xpath('//reseller/get/result') as $item) { try { $this->_checkErrors($item); foreach($item->data->ippool->ip as $ip) { if($ip->{'ip-type'}=="exclusive") { $ipListUse[(string)$ip->{'ip-address'}] = (string)$ip->{'ip-address'}; } } } catch (Exception $e) { if (Plesk_Api::ERROR_OBJECT_NOT_FOUND != $e->getCode()) { throw $e; } } } }
/templates/api/1.6.3.2/resellers_get.tpl
<!-- Copyright 1999-2016. Parallels IP Holdings GmbH. --> <reseller> <get> <filter/> <dataset> <ippool/> </dataset> </get> </reseller>
This repository is no longer maintained. All questions regarding the WHMCS Plesk Provisioning Module should be addressed to WHMCS Technical Support. https://www.whmcs.com/submit-a-ticket/