Help with a remote ssh df -h


This is most likely easy but I need some help.
I have a command_line sensor running df -h | grep … on a remote server

I then see the sensor in home assistant like this:


So how can I extract the values with templating or something else to use the values?
The format is ofc not i json so I am lost…

Some more specifics about what exactly you want to extract and how you want to use it might be helpful. But as a start, you could do something like:

{{ states(ENTITY_ID).split(' ')[1] }}

Which would return the string ‘40G’ from your example.