glpi-project / glpi-agent

GLPI Agent
GNU General Public License v2.0
252 stars 61 forks source link

Windows GLPI-Agent 1.10 can't decode JSON content, starting with #740

Closed Ludo-code closed 3 months ago

Ludo-code commented 3 months ago

Bug reporting acknowledgment

Yes, I read it

Professional support

None

Describe the bug

Just the inventory run fine and importing to glpi but with error :

[error] [http client] Can't decode JSON content, starting with:

<!DOCTYPE html>
<html lang="fr"       >
<head>
   <title>Authentification - GLPI</title>

   <meta charset="utf-8" />
...
[info] Collect task not supported by server0
[info] running task ESX
[error] [http client] Can't decode JSON content, starting with:

<!DOCTYPE html>
<html lang="fr"       >
<head>
   <title>Authentification - GLPI</title>

   <meta charset="utf-8" />
...
[info] ESX task not supported by server0

To reproduce

  1. Run Glpi-agent with a server configured in the base url https://myglpi.mydomain/glpi/
  2. See error of decode JSON error in console
  3. Check your GLPI to see that the computer is inventoried

Expected behavior

He must don't have JSON decode error

Operating system

Windows

GLPI Agent version

v1.10

GLPI version

10.0.12

GLPIInventory plugin or other plugin version

Not applicable

Additional context

Using built in glpi inventory server no plugin.

g-bougard commented 3 months ago

Hi @Ludo-code

you have a server configuration issue: agent is reaching the GLPI authentication page.

Did you ever enable inventory in GLPI ? It is disabled by default now.