Skip to content

Track last_started date of jails #632

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

Open
gronke opened this issue Feb 3, 2019 · 3 comments
Open

Track last_started date of jails #632

gronke opened this issue Feb 3, 2019 · 3 comments

Comments

@gronke
Copy link
Member

gronke commented Feb 3, 2019

It is reasonable to track when a jail was last started successfully. Unlike iocage this should not be stored in a Jail configuration.

@igalic
Copy link
Collaborator

igalic commented Feb 3, 2019

this is something an external orchestration tool would have a much easier time tracking. and a much more understandable need for doing it to begin with

@himrock922
Copy link

If the orchestration tool makes track, Should libioc returns only response with last_started?

https://github.com/bsdci/libioc/blob/master/libioc/Jail.py#L2289

If above line changes that like return response datetime for last_started, jail config not store and return last_started...?

@gronke
Copy link
Member Author

gronke commented Feb 10, 2019

We currently fork a process to query jail state. In Python this is an expensive operation, so that we first need to create interfaces for libc jail_get and jail_set.

@fabianfreyer has pioneered on a Rust library with Python interface that is about to be utilized in #594. I'm not so much in favor to depend on Rust, but after a review, it is a well designed library.

With this we will be able to always query jail state on the fly at low cost, so that changed state can easily be signaled from changing operations (I'm thinking about the JailEvent informing about state change).

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

3 participants