Help with automation repeated each hours

Hi there !
I want to execute a Shell Command each Hours.
I don’t find how to do it on automation…

I created shell command on Configuration.yaml

    mesure_forced: mosquitto_pub -h *my_ip_address* -p *port* -m '' -t 'blueriiot/commands/release_last_unprocessed/ID' -u '*user*' -P '*password*'

But don’t know how to add it on automation and repeat it each hours


Look at the trigger documentation. This one in particular:

Ok for triggering.
Regarding using ssh on automation ?
I don’t know how to implement it

Something like:

  - platform: time_pattern
    hours: /1
condition: []
  - service: shell_command.mesure_forced
    data: {}
mode: single
1 Like

Thanks for example :+1:

I have this error message

Mesure piscine use unknown service
The automation “Mesure piscine” (automation.automation_3) has an action that calls an unknown service: shell_command.mesure_forced.

Here is step details

Did you restart home assistant after creating your shell command?

Is the service available in Developer Tools → Services?

I just restarted HA and now it’s working :+1:
Thanks for your help tom_I