[Support] Fork Unraid API-RE


Recommended Posts

3 hours ago, johntdyer said:

Both, disabled in settings and I dont have any

Could you try the following tag: bokker/unraidapi-re:6.12-no-vm 

 

I added the following 2 variables which can be set to false using docker env variables

 

VM_ENABLE, DOCKER_ENABLE

 

image.png.d39b9d54754b99f65417967fe783b3ad.png

 

This should disable VM checking for you. I will have to do more work on it, since I think its possible to have this work just by detecting if the VM tab is available or not in the UI, without using the env variable.

Link to comment

/mnt/user/appdata/Unraid-API/servers.json

 

```

{
    "https://unraid.xxxxx.xxxxx": {
        "serverDetails": {
            "arrayStatus": "Started",
            "moverRunning": true,
            "parityCheckRunning": true,
            "title": "vault",
            "cpu": "Common KVM  @ 2000 MHz",
            "memory": "32 GiB RAM Multi-bit ECC ",
            "motherboard": "  ",
            "diskSpace": "24.1 TB used of 58 TB (41.5 %)",
            "cacheSpace": "26.6 GB used of 265 GB (10.0 %)",
            "version": "6.12.3",
            "arrayUsedSpace": "24.1 TB",
            "arrayTotalSpace": "58 TB",
            "arrayFreeSpace": "33.9 TB",
            "cacheUsedSpace": "26.6 GB",
            "cacheTotalSpace": "265 GB",
            "cacheFreeSpace": "238.4 GB",
            "on": true
        },
        "docker": {
            "details": {
                "images": {
                    "245078241b19": {
                        "imageUrl": "/webGui/images/disk.png",
                        "imageId": "245078241b19",
                        "created": "Created 2 days ago"
                    },
                    "2ddd2e111d89": {
                        "imageUrl": "/webGui/images/disk.png",
                        "imageId": "2ddd2e111d89",
                        "created": "Created 2 days ago"
                    },
                    "df91f6deadde": {
                        "imageUrl": "/webGui/images/disk.png",
                        "imageId": "df91f6deadde",
                        "created": "Created 1 year ago"
                    },
                    "2154b5734a30": {
                        "imageUrl": "/webGui/images/disk.png",
                        "imageId": "2154b5734a30",
                        "created": "Created 1 year ago"
                    }
                },
                "containers": {
                    "f2cbb7d93588": {
                        "imageUrl": "/state/plugins/dynamix.docker.manager/images/proxmox-backup-server-icon.png",
                        "name": "proxmox-backup-server",
                        "status": "stopped",
                        "containerId": "f2cbb7d93588",
                        "tag": "v2.3.2",
                        "uptoDate": "up-to-date"
                    },
                
                    "ac662b94a351": {
                        "imageUrl": "/state/plugins/dynamix.docker.manager/images/Unraid-API-RE-icon.png",
                        "name": "Unraid-API-RE",
                        "status": "started",
                        "containerId": "ac662b94a351",
                        "tag": "6.12-no-vm",
                        "uptoDate": "up-to-date"
                    }
                    
                }
            }
        },
        "vm": {
            "details": {}
        },
        "pciDetails": [],
        "status": "offline",
        "usbDetails": []
    }
}

```

Link to comment
On 8/15/2023 at 10:59 PM, johntdyer said:

Still getting the error here is my config

 

image.thumb.png.e24486914c6bd2d39b60ffe0149c9f94.png

 

 

Sorry, I accidentally wrote the wrong variable in the code, if you update the container it should work as expected

 

EDIT: you can switch back to 6.12, and remove the env variables, it should work without them

Edited by BoKKeR
Link to comment
On 7/28/2023 at 1:07 PM, valiente said:

I just updated and still seeing my HA logs spiking:

 

Logger: homeassistant
Source: helpers/entity_platform.py:750
First occurred: 12:51:59 (781 occurrences)
Last logged: 13:05:25

Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 504, in async_add_entities
    await asyncio.gather(*tasks)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 750, in _async_add_entity
    raise HomeAssistantError(f"Invalid entity ID: {entity.entity_id}")
homeassistant.exceptions.HomeAssistantError: Invalid entity ID: binary_sensor.brute_vm_home_assistant_usb_nbsp_nbsp_nbsp_nbsp_nbsp_nbsp_nbsp_input_type_checkbox_name_usbopt_0463_ffff_id_usbopt0_value_0463_ffff_nbsp_nbsp_nbsp_nbsp_nbsp_input_type_number_size_5_maxlength_5_id_usbboot0_class_narrow_bootorder_style_width_

 

Logger: homeassistant.components.binary_sensor
Source: helpers/entity_platform.py:750
Integration: Binary Sensor (documentation, issues)
First occurred: 12:51:59 (461 occurrences)
Last logged: 13:07:22

Error adding entities for domain binary_sensor with platform mqtt
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 504, in async_add_entities
    await asyncio.gather(*tasks)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 750, in _async_add_entity
    raise HomeAssistantError(f"Invalid entity ID: {entity.entity_id}")
homeassistant.exceptions.HomeAssistantError: Invalid entity ID: binary_sensor.brute_vm_home_assistant_usb_nbsp_nbsp_nbsp_nbsp_nbsp_nbsp_nbsp_input_type_checkbox_name_usbopt_0463_ffff_id_usbopt0_value_0463_ffff_nbsp_nbsp_nbsp_nbsp_nbsp_input_type_number_size_5_maxlength_5_id_usbboot0_class_narrow_bootorder_style_width_

 

781 entries in 15 minutes...

 

image.thumb.png.e3fb2c7c19edaf3cbebb957f04237d92.png

Any updates on this?

 

Just checked my HA logs and found this:

Logger: homeassistant

Source: helpers/entity_platform.py:712

First occurred: 20 August 2023 at 19:45:06 (40192 occurrences)

Last logged: 19:16:42

 

Error doing job: Task exception was never retrieved

Traceback (most recent call last):

  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 510, in async_add_entities

    await asyncio.gather(*tasks)

  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 712, in _async_add_entity

    raise HomeAssistantError(f"Invalid entity ID: {entity.entity_id}")

homeassistant.exceptions.HomeAssistantError: Invalid entity ID: binary_sensor.brute_vm_home_assistant_usb_nbsp_nbsp_nbsp_nbsp_nbsp_nbsp_nbsp_input_type_checkbox_name_usbopt_0463_ffff_id_usbopt0_value_0463_ffff_nbsp_nbsp_nbsp_nbsp_nbsp_input_type_number_size_5_maxlength_5_id_usbboot0_class_narrow_bootorder_style_width_

 

Link to comment

Hi,

first of all thanks to @BoKKeR for supporting this API again.
I just have a minor problem that when I shutdown UNRAID via the MQTT power_off switch it changes from the state on: true to on: false for a short time and directly back to on:true.
Means that the last MQTT state in Home Assistant is on:true and my POWER ON / OFF script does not work because there is a condition that checks if UNRAID is on or off state. Does anyone else have this problem?

Thanks
 

 

Link to comment
1 hour ago, Orishas said:

Hi,

first of all thanks to @BoKKeR for supporting this API again.
I just have a minor problem that when I shutdown UNRAID via the MQTT power_off switch it changes from the state on: true to on: false for a short time and directly back to on:true.
Means that the last MQTT state in Home Assistant is on:true and my POWER ON / OFF script does not work because there is a condition that checks if UNRAID is on or off state. Does anyone else have this problem?

Thanks
 

 

 

Not happening for me atleast. 

 

 

 

Link to comment
  • 2 weeks later...
2 hours ago, ZynanBob said:

Hey, thanks for continuing this project!

 

One Question: After restarting HA the entities of unraid goes unknown until I restart the api docker. Is there a fix for this?

 

I created a fix for this, could you try it by changing your docker tag from bokker/unraidapi-re:6.12 to bokker/unraidapi-re:6.12-retain

Link to comment
On 9/14/2023 at 11:51 AM, BoKKeR said:

 

I created a fix for this, could you try it by changing your docker tag from bokker/unraidapi-re:6.12 to bokker/unraidapi-re:6.12-retain

Hi,

 

i tested this release it fixes problem that the entity becomes unavailable after a HA restart, but now it always retains the status on:true

Link to comment
5 hours ago, Orishas said:

Hi,

 

i tested this release it fixes problem that the entity becomes unavailable after a HA restart, but now it always retains the status on:true

 

I tested it to but and the issues with unavailabe after HA restart seems fixed. What do you mean by that it retains statsus on:true?

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.