-
Notifications
You must be signed in to change notification settings - Fork 519
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
Enable oci hooks through API settings #1872
Enable oci hooks through API settings #1872
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This provisionally looks good to me.
We need a migration to remove this setting on downgrade, as discussed out of github. But this otherwise LGTM. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't we need a migration?
@@ -1,7 +1,6 @@ | |||
%global _cross_first_party 1 | |||
%global _is_k8s_variant %(if echo %{_cross_variant} | grep -Fqw "k8s"; then echo 1; else echo 0; fi) | |||
%global _is_aws_variant %(if echo %{_cross_variant} | grep -Fqw "aws"; then echo 1; else echo 0; fi) | |||
%global _is_vendor_variant %(if echo %{_cross_variant} | grep -Fqw "nvidia"; then echo 1; else echo 0; fi) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this on develop?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was, yeah, the line was added with shimpei, because we didn't want to use it as the default runtime for all variants. But now we do 👍
Oh, things are happening to fast, I can't keep up 😅 |
d6e1828
to
47ecbaf
Compare
Forced push includes:
|
47ecbaf
to
b4b0e7a
Compare
Forced push includes rebase to upstream. |
With shimpei as the default runtime for container runtimes, we can run OCI hooks provided through API settings. This commit needs the OCI settings to properly work, since shimpei reads a hooks file generated by changes in the settings. Signed-off-by: Arnaldo Garcia Rincon <[email protected]>
b4b0e7a
to
59f1b0f
Compare
Forced push includes:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, pending testing! 🚢
README.md
Outdated
#### OCI Hooks settings | ||
|
||
Bottlerocket allows you to opt-in to use additional [OCI hooks](https://github.com/opencontainers/runtime-spec/blob/main/runtime.md#lifecycle) for your orchestrated containers. | ||
Once you opt-in to use additional OCI hooks, the new orchestrated containers will be configured with them, but the existing containers won't be changed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit:
Once you opt-in to use additional OCI hooks, the new orchestrated containers will be configured with them, but the existing containers won't be changed. | |
Once you opt-in to using additional OCI hooks, newly-orchestrated containers will be configured with them. Existing containers won't be changed. |
We always include log4j-hotpatch in all variants Signed-off-by: Arnaldo Garcia Rincon <[email protected]>
The oci-hooks setting allows a user to enable OCI hooks provided by the OS. For the time being, the only OCI hook provided is the `log4j2-hotpatch`, which applies the hotpatch for Apache Log4j2 to containers running JVMs. Signed-off-by: Arnaldo Garcia Rincon <[email protected]>
59f1b0f
to
709db49
Compare
Forced push includes:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Issue number:
N / A
Description of changes:
The oci-hooks setting allows a user to enable OCI hooks provided by the OS. For the time being, the only OCI hook provided is the
log4j2-hotpatch
, which applies the hotpatch for Apache Log4j2 to containers running JVMs.Remaining work:
Testing done:
In aws-ecs/aws-k8s-1.21:
Run workloads with java services, with and without enabling the
log4j-hotpatch
hook. I saw the containers being patched, and the logs generated in/dev/shm/hotdog.log
.Terms of contribution:
By submitting this pull request, I agree that this contribution is dual-licensed under the terms of both the Apache License, version 2.0, and the MIT license.