Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

start_watchdog should support init system shell #127

Open
alesavin opened this issue Apr 19, 2022 · 1 comment
Open

start_watchdog should support init system shell #127

alesavin opened this issue Apr 19, 2022 · 1 comment

Comments

@alesavin
Copy link

Now mount.efs/start_watchdog support init systems

  • init
  • systemd
  • launchd
    with default resolving of init systam by cat /proc/1/comm. In case resolving ends with non-supported init system warning is shown and watchdog isn't started. In a system (container) without any option from list above (init, launchd aren't avaliable, systemd requires additional setup) we can't easily track stunnel leftovers.

Proposal is to add support for init system based on raw shell, for such case

  • existence of PID file (/var/run/efs/amazon-efs-mount-watchdog.pid) is checked and in case it exists existence of process with PID
  • in case we have no file or process
/usr/bin/amazon-efs-mount-watchdog &
echo $! > /var/run/efs/amazon-efs-mount-watchdog.pid
  • otherwise report we have watchdog process is already running
@RyanStan
Copy link
Member

Thanks for bringing this to our attention!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants