Can't use '/local' directory location on Dietpi [Solved]

I’m aiming to use the picture glance card in Lovelace, but I can’t work out where to put the image file on a Dietpi.

I’ve checked that the directories are all owned by the ‘dietpi’ user (which seems to be the norm for a Dietpi).

I’ve placed the image in:

/mnt/dietpi_userdata/homeassistant/config/www

But I’ve had no luck, just the gray image broken background.

Anyone have any pointers?

Is /mnt/dietpie_userdata/homeassistant/config the location of configuration.yaml?

After you created www/ did you restart Home Assistant as explained here?

Why read the documentation or search when you can just ask here? :wink:

I also use DietPi and the default config directory is /mnt/dietpi_userdata/homeassistant (/home/homeassistant/.homeassistant is a symlink to that path).

Thanks, yeah I did the reboot prior - no luck.

All the yaml files are stored at:

/mnt/dietpi_userdata/homeassistant

The image files I’ve placed in:

/mnt/dietpi_userdata/homeassistant/config/www as per the norm.

Still can’t get it to work though :frowning:

edit

I can’t access local files through the standard link either, i.e.

http://your.domain:8123/local/

Cheers, have you been able to use static image files using the /local location then?

I’ve tried using the full path (as well as /local) in two ways to no avail:

/mnt/dietpi_userdata/homeassistant/config/www

and

/mnt/dietpi_userdata/homeassistant/

Since you are not using Hass.io, that is not the norm. Please read the docs @Tinkerer posted.

It’s the default location for homeassistant files in Dietpi, I’ve added in the /config/www part as they’re not there pre-installed.

This is the way to do things as I understand the documentation, I’ll see what docs there are on the Dietpi side of things.

What folder contains configuration.yaml?

1 Like

The full path for configuration.yaml and all the other hass yaml files in Dietpi is:

/mnt/dietpi_userdata/homeassistant/

If you want to use Home Assistant to host or serve static files then create a directory called www under the configuration path (/config on Hass.io, .homeassistant elsewhere).

/config/www is the path on Hassio
.homeassistant/www is the path elsewhere.

.homeassistant/config/www is not a valid path.

On DietPi, /mnt/dietpi_userdata/homeassistant/ is the same as .homeassistant.

2 Likes

In other words the path you want is

/mnt/dietpi_userdata/homeassistant/www

not

/mnt/dietpi_userdata/homeassistant/config/www
1 Like

In other words the path you want is

/mnt/dietpi_userdata/homeassistant/www

Yippee!!! Thanks a million, that did the trick :slight_smile: