Sanderhuisman / home-assistant-custom-components

🏡 Custom components for Home-Assistant
https://www.home-assistant.io/
Apache License 2.0
33 stars 12 forks source link

Added state with Docker alike state like 'Up 10 days', 'Exit (0) 5 days ago' #5

Open ualex73 opened 5 years ago

ualex73 commented 5 years ago

I created this pull request to add a value to a Docker container which gives the Docker alike status back like:

Up 6 days Up 6 days (Paused) Exited (0) 2 months ago Restarting (99) 5 seconds ago

The status of the "_status" and "_uptime" are then combined into 1 instead I need to display 2 values (for running, for not running containers the value of uptime is completely wrong). Maybe a toggle for the "*_status" could be an option to implement this?

This mimics the hadockermon output :-)

I don't expect it will be merged/accepted as-is, but if you include this output type into the main code, I will be grateful.

Sanderhuisman commented 5 years ago

I will have a look at the implementation, but I appreciate the proposed feature!