Leds Keyboard on Wayland

Hi, I would like to know how I can start my user’s session, already passing a certain command to him.

The command in question, serves to turn on the leds of my keyboard.
Before, when you use Xorg, you used the:

xset led 3

And configured a command so that the session, already started with this command.

However, I have no idea how to do it, in Wayland, would it be the same?

The command I want to start is as follows:

sudo sh -c 'echo 1 > /sys/class/leds/input6::scrolllock/brightness'

How could I do this mission?

May be you can create custom systemd service that will execute the script containing your command.

Something like this tutorial. You could also specify on what situation where the script will executed. But I’m no expert on that, may be you could read any tutorial or doc related to create systemd service.

Thanks guy