I have a container running a workload that takes unpredictable amounts of time to finish. I would like to have it be able to notify the host when a job is finished so that it can be snapshotted. I'm wondering if there are any inbuilt tools for managing this. At a glance I have not found any.
I could cobble together a shell script that remotes into the host and requests that, but that has security implications unless I configure a user on the host with a restricted command set. I could also create a simple daemon that runs on the host to respond to these requests, but that still has similar portability problems in that it requires the daemon to be installed on the host. A third option would be to have a daemon on the host monitoring something like a .pid or log file, but that again requires special configuration on a per host basis.
I'm open to suggestions.
I could cobble together a shell script that remotes into the host and requests that, but that has security implications unless I configure a user on the host with a restricted command set. I could also create a simple daemon that runs on the host to respond to these requests, but that still has similar portability problems in that it requires the daemon to be installed on the host. A third option would be to have a daemon on the host monitoring something like a .pid or log file, but that again requires special configuration on a per host basis.
I'm open to suggestions.