feat(nodeclass): add agentList to enable OCI agent plugins on launched instances#23
Merged
arindam-bandyopadhyay merged 1 commit intoJun 19, 2026
Conversation
|
Thank you for your pull request and welcome to our community! To contribute, please sign the Oracle Contributor Agreement (OCA).
To sign the OCA, please create an Oracle account and sign the OCA in Oracle's Contributor Agreement Application. When signing the OCA, please provide your GitHub username. After signing the OCA and getting an OCA approval from Oracle, this PR will be automatically updated. If you are an Oracle employee, please make sure that you are a member of the main Oracle GitHub organization, and your membership in this organization is public. |
57fdb44 to
fb9b390
Compare
|
Thank you for signing the OCA. |
arindam-bandyopadhyay
requested changes
Jun 16, 2026
p2pdkivenko
added a commit
to p2pdkivenko/karpenter-provider-oci
that referenced
this pull request
Jun 17, 2026
…rage Address PR oracle#23 review feedback: - Include Spec.AgentList in HashNodeClassSpec via createStaticFieldsClone so that changes to the agent plugin list are detected as node-class drift and trigger node replacement (agentList is launch-time-only config, like SshAuthorizedKeys/PreBootstrapInitScript). Add a unit assertion verifying the hash changes when AgentList is mutated. - Add an e2e test (TestAgentConfig/verifyAgentConfig) that patches the OCINodeClass with an agentList, waits for a node, fetches the OCI instance and asserts each plugin is present with DesiredState=ENABLED. Wire it into the flannel and NPN end-to-end flows, and expose AgentList on the e2e OCINodeClass config.
arindam-bandyopadhyay
requested changes
Jun 17, 2026
…d instances Add an `agentList` field to OCINodeClass that enables the named Oracle Cloud Agent plugins on launched instances via LaunchInstanceAgentConfigDetails. Each listed plugin is set to ENABLED at launch time; plugins not listed keep their image default. The field is included in HashNodeClassSpec so changing agentList produces a new nodeclass hash and triggers drift -> node replacement. Adds unit coverage for buildAgentConfig and the hash behavior, plus e2e coverage (TestAgentConfig) on the Flannel flow.
5d3e5ba to
0e27d5c
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds a new
agentListfield toOCINodeClassSpecso users can enable Oracle Cloud Agent plugins (Bastion, Block Volume Management, Compute Instance Monitoring, OS Management Service Agent, etc.) on Karpenter-launched instances without having to ship custom cloud-init.Each entry in the list is forwarded to
LaunchInstanceDetails.AgentConfig.PluginsConfigwithDesiredState=ENABLED. When the field is empty or unset,AgentConfigstays nil and behavior is unchanged from today (image defaults apply). The same shape is already used by the sibling projectzoom/karpenter-oci, so existing user manifests transfer over directly.Example:
Fixes #22
Type of change
How Has This Been Tested?
New unit test
TestProvider_BuildAgentConfiginpkg/providers/instance/provider_test.gocovering nil, empty, single-plugin, and multi-plugin cases.Existing instance provider test suite (
go test ./pkg/providers/instance/...) passes locally.make gogenregenerates CRD YAML andzz_generated.deepcopy.gocleanly; both regenerated artifacts are included in the diff.go build ./...succeeds for all packages touched by this change. (The pre-existingtest/e2e/utils.go: undefined: NodePoolLabelbuild failure onmainis unrelated to this change.)Kubernetes version: 1.30
OKE version: n/a (provider built locally)
Karpenter Provider OCI version: built from this branch
Installation method: local run (
go test)Checklist:
agentListfield documenting accepted plugin names and ENABLED-only semantics)