Skip to content

Commit

Permalink
Fix systemd regression due to VyOS support bug
Browse files Browse the repository at this point in the history
Fixes #928
  • Loading branch information
rs committed Apr 28, 2024
1 parent 5a25156 commit 03bc59b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions host/service/vyos/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import (
)

func isVyOS() bool {
if st, err := os.Stat("/config/scripts/"); err != nil || !st.IsDir() {
if _, err = os.Stat("/usr/libexec/vyos/init/vyos-router"); err != nil {
if st, err := os.Stat("/config/scripts/"); err == nil && st.IsDir() {
if _, err = os.Stat("/usr/libexec/vyos/init/vyos-router"); err == nil {
return true
}
}
Expand Down

0 comments on commit 03bc59b

Please sign in to comment.