Skip to content

Commit

Permalink
chore: make service restart automatically and timeout if it fails to …
Browse files Browse the repository at this point in the history
…start
  • Loading branch information
Jadon Wolffs committed Apr 8, 2024
1 parent 45aba93 commit a5b7679
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import (
serial "github.com/wolffshots/phocus/v2/serial" // comms with inverter
)

const version = "v2.9.5"
const version = "v2.9.6"

type Configuration struct {
Serial struct {
Expand Down
4 changes: 4 additions & 0 deletions phocus.service
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ After = network.target
[Service]
ExecStart = /usr/bin/phocus_app/phocus
WorkingDirectory = /usr/bin/phocus_app
Type = simple
Restart = always
KillMode = process
TimeoutSec = 300

[Install]
WantedBy = multi-user.target

0 comments on commit a5b7679

Please sign in to comment.