feat: allow restrict Pomodoro via password

- introduce password flag in server command line options
- update clientCommand model
- add password requirement for controlling the Pomodoro timer
- document password in README
This commit is contained in:
Sebastian Mark 2024-10-21 15:36:26 +02:00
parent 8deb642a7e
commit f991ba885d
5 changed files with 38 additions and 26 deletions

View file

@ -8,8 +8,9 @@ import (
// ClientCommand represents a command from the client (start/stop).
type ClientCommand struct {
Command string `json:"command"`
Config GoTomatoPomodoroConfig `json:"config"`
Command string `json:"command"` // comman send to the server
Password string `json:"password"` // pomodoro control password
Config GoTomatoPomodoroConfig `json:"config"` // pomodoro config
}
type Client struct {