Can run `systemctl --user` commands, protected with shared passwords.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
Arthur POULET 95007bbe70
add readme
8 months ago
views fix app 8 months ago
.env.sample add port binding 8 months ago
.gitignore init server 8 months ago
.ruby-version init server 8 months ago
Gemfile init server 8 months ago
Gemfile.lock init server 8 months ago
README.md add readme 8 months ago
app.rb add port binding 8 months ago

README.md

Remote control for systemctl --user start/stop

Install

Add systemctl service

Add a user service: $HOME/.config/systemd/user/default.target.wants/remotesystemctl.service

[Unit]
Description=RemoteSystemctl
Documentation=

[Service]
ExecStart=$HOME/RemoteSystemctl/app.rb
Restart=on-failure
RestartSec=5
WorkingDirectory=$HOME/RemoteSystemctl

[Install]
WantedBy=default.target

Enable it at reboot

systemctl --user enable remotesystemctl.service

Start it right now

systemctl --user start remotesystemctl.service

Configure

Copy .env.sample to .env.local and customize. You can add/remove services using their exact name with PASSWORD_xxx env variables.

Setup ruby

Have ruby >= 3.1 installed with gems and the bundler gem.

Then simply use bundle install to install the dependencies (see the Gemfile, there should a very low amount of dependencies).