Lovelace: Sun Card

I tried this configuration too… no success

type: 'custom:sun-card'
entities:
  time: sensor.time
  moon_phase: sensor.moon
  sunrise: sensor.sunrise
  sunset: sensor.sunset
style: |
  ha-card {
    --sc-sunbeam-color: blue;
    --sc-sun-color: green;
    --sc-horizon-color: orange;
  }
animation: true
meridiem: false

Has something changed with the HACS install? I get a “Repostitory structure for v5.0 is not compliant” error when trying to add this github as a repo.

set the Category to ‘Lovelace’

Oh! That was kind of obvious, in retrospect. Thanks!

1 Like

Hi all. I’ve made ha checking before upgrade to 2021.5.1
The result is an error on platform: sun2
I don’t have upgraded HA yet
Do you have any advice?

Did you bother checking if sun2 has been updated?

Hi David,
I’ve the 5.0 Version
It’s the last, I suppose
this is the reported error

Failed config
General Errors:
- Platform error sensor.sun2 - cannot import name ‘AstralError’ from ‘astral’ (/usr/local/lib/python3.8/site-packages/astral/init.py)

You are probably confusing the card with the component. The latest version of sun2 is version 2 and it was specifically released for the change in HA.

You are right David
I had not seen that there was an upgrade to 2.0 of the component.
I have now updated all documents in Custom_component
Thanks very much.
I’m checking now for the HA upgrade.
I’ve now proceed to 2021.5.1 upgrade without problems

Just to note there is a ‘Sun Card’ in the HACS directory (I think).

Perhaps this should be renamed to sun2-card to avoid conflict?

Both cards have their pros and cons.

1 Like

Is this Project still in development? Latest files on github are from 17 Jun 2020.

I need help to get this working in synology dockercontainer.
Installed with this tutorial: https://mariushosting.com/how-to-install-home-assistant-on-your-synology-nas/

Now i want to manually install the files, but the mentioned folders/pathes are not here.
any advice/tutorial how to install within docker?

thx

Synology DSM 7.1.xxx with Home Assistant 2022.8.6

I agree with @baz123 !
Is it possible to rename it?
I’m having problems with the two cards because they conflict
Thanks