The-Network-Crew / Proxmox-VE-for-WHMCS

Proxmox VM/CT Module for the WHMCS Automation & Billing System.
https://marketplace.whmcs.com/product/6935-proxmox-ve-for-whmcs#reviews
GNU General Public License v3.0
161 stars 52 forks source link

WHMCS Connection Test (#29 dup); /nodes/pve//#/config (2x / = illegal op) return of #36? #53

Closed wawelon closed 12 months ago

wawelon commented 12 months ago

Error - test connect

PVE2 API: This API Request Failed. HTTP CODE: 401, HTTP ERROR: HTTP/1.1 401 No ticket, REPLY INFO:

lsthompson commented 12 months ago

As in, this is via WHMCS Admin > Servers > your PVE? Trying to get WHMCS and PVE integrated, right?

Once you've configured it with root user and password, can you follow the other steps and create a service?

As currently the connection test is awry.

wawelon commented 12 months ago

client area > services

PVE2_Exception: PVE2 API: This API Request Failed. HTTP CODE: 401, HTTP ERROR: HTTP/1.1 401 No ticket, REPLY INFO: in /sites/noeye.pp.ua/modules/addons/pvewhmcs/proxmox.php:264

Stack trace:
#0 /sites/noeye.pp.ua/modules/addons/pvewhmcs/proxmox.php(574): PVE2_API->action('/nodes', 'GET')
#1 /sites/noeye.pp.ua/modules/addons/pvewhmcs/proxmox.php(291): PVE2_API->get('/nodes')
#2 /sites/noeye.pp.ua/modules/addons/pvewhmcs/proxmox.php(120): PVE2_API->reload_node_list()
#3 /sites/noeye.pp.ua/modules/servers/pvewhmcs/pvewhmcs.php(608): PVE2_API->login()
#4 [internal function]: pvewhmcs_ClientArea(Array)
#5 /sites/noeye.pp.ua/vendor/whmcs/whmcs-foundation/lib/Module/AbstractModule.php(0): call_user_func('pvewhmcs_Client...', Array)
#6 /sites/noeye.pp.ua/vendor/whmcs/whmcs-foundation/lib/Module/Server.php(0): WHMCS\Module\AbstractModule->call('ClientArea', Array)
#7 /sites/noeye.pp.ua/vendor/whmcs/whmcs-foundation/lib/Service.php(0): WHMCS\Module\Server->call('ClientArea', Array)
#8 /sites/noeye.pp.ua/clientarea.php(0): WHMCS\Service->moduleCall('ClientArea', Array)
#9 {main}
lsthompson commented 12 months ago

So yes, it was, and now you've tested via another way? Same error if so, no PVE auth ticket.

What do your Proxmox logs say when you attempt these actions?

You're sure you've done all the module config steps?

wawelon commented 12 months ago

So yes, that's what happened, and now you checked in another way? If yes, then the same error: no PVE authentication ticket.

What do your Proxmox logs say when you try these actions? Success

Are you sure you have completed all the steps to configure the module? YES

New Error

PVE2_Exception: PVE2 API: This API Request Failed. HTTP CODE: 501, HTTP ERROR: HTTP/1.1 501 Method 'GET /nodes/pve//2/config' not implemented, REPLY INFO: {"data":null} in /sites/noeye.pp.ua/modules/addons/pvewhmcs/proxmox.php:264

Stack trace:
#0 /sites/noeye.pp.ua/modules/addons/pvewhmcs/proxmox.php(574): PVE2_API->action('/nodes/pve//2/c...', 'GET')
#1 /sites/noeye.pp.ua/modules/servers/pvewhmcs/pvewhmcs.php(616): PVE2_API->get('/nodes/pve//2/c...')
#2 [internal function]: pvewhmcs_ClientArea(Array)
#3 /sites/noeye.pp.ua/vendor/whmcs/whmcs-foundation/lib/Module/AbstractModule.php(0): call_user_func('pvewhmcs_Client...', Array)
#4 /sites/noeye.pp.ua/vendor/whmcs/whmcs-foundation/lib/Module/Server.php(0): WHMCS\Module\AbstractModule->call('ClientArea', Array)
#5 /sites/noeye.pp.ua/vendor/whmcs/whmcs-foundation/lib/Service.php(0): WHMCS\Module\Server->call('ClientArea', Array)
#6 /sites/noeye.pp.ua/clientarea.php(0): WHMCS\Service->moduleCall('ClientArea', Array)
#7 {main}

help please

message proxmox successfull auth for user 'root@pam'

lsthompson commented 12 months ago

HTTP ERROR: HTTP/1.1 501 Method 'GET /nodes/pve//2/config' not implemented,

This sounds like a misconfiguration in your setup. Others would be reporting it if not.

Are you able to share screenshots of all of your configuration areas please, for us to check?

The format is wrong. The code mentioned pulls it together as: $vm_config=$proxmox->get('/nodes/'.$first_node.'/'.$guest->vtype.'/'.$params['serviceid'] .'/config') ;

So we should be seeing more like /nodes/1/qemu/101/config in the request, if all is configured OK.

Did you explicitly save the WHMCS Service with the Module Plan against it, via WHMCS Settings? I would think so, as per #36 there should be an error that tells you about that condition, and to fix it.

Your request is missing qemu or lxc - so the PVE API does not understand it. Cause is most likely your config.

wawelon commented 12 months ago

Без імені Без імені2 Без імені3

I didn't use whmcs Now I’m testing what and how to create my own vps service

lsthompson commented 12 months ago

I didn't use whmcs

What do you mean? How were you doing it?

Now I’m testing what and how to create my own vps service

What about your WHMCS > Settings > Products/Services > Service for PVE VM/CT tabs/config?

wawelon commented 12 months ago

Без імені4 this config?

lsthompson commented 12 months ago

Hit save there, and then send screenshot of the next tab along too - Custom Fields.

wawelon commented 12 months ago

Без імені6

lsthompson commented 12 months ago

OK, so you haven't fully followed README.md instructions? Need to have a way to provision it.

https://github.com/The-Network-Crew/Proxmox-VE-for-WHMCS#%EF%B8%8F-vmct-plans-setting-everything-up-%EF%B8%8F

As I've asked before, can you please make sure you've followed the full configuration properly? Thanks!

wawelon commented 12 months ago

I don’t understand anything how to configure it correctly

lsthompson commented 12 months ago

Okay, thanks for letting us know.

Unfortunately you will need to spend more time getting to understand the configuration so you can get it working properly in your environment.

Once you're across the requirements and have it prepared properly please raise a new issue with comprehensive information. Thanks!