-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[SecuritySolution] Disable K8S link on serverless #204350
Conversation
🤖 Jobs for this PR can be triggered through checkboxes. 🚧
ℹ️ To trigger the CI, please tick the checkbox below 👇
|
): Promise<LinkItem> => { | ||
const fleetAuthz = plugins.fleet?.authz; | ||
const currentUser = await plugins.security.authc.getCurrentUser(); | ||
export const getManagementFilteredLinks = async (services: StartServices): Promise<LinkItem> => { |
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.
Changed core: CoreStart, plugins: StartPlugins
parameters by services: StartServices
.
Files by Code Ownerelastic/kibana-cloud-security-posture
elastic/kibana-core
elastic/kibana-security
elastic/security-defend-workflows
elastic/security-solution
elastic/security-threat-hunting-explore
|
@elasticmachine merge upstream |
…_serverless' into 10735/hide_k8s_link_serverless
💔 Build Failed
Failed CI StepsTest Failures
Metrics [docs]Async chunks
Page load bundle
History
|
@elasticmachine merge upstream |
Summary
The approach uses
offeringSettings
config to disable that in serverless.Approach
Make
services.configSettings.defendForContainersEnabled
flag available inside thegetFilteredLinks
function to remove thekubernetes
link when disabled.To do so I needed to change the parameters received by the
getFilteredLinks
function. Now it takes the whole StartServices object, instead of CoreStart and PluginsStart separately.Side effects
getManagementFilteredLinks
has been refactored to takeservices
, and the test has been updated.generateServices
function now caches the generated StartServices, this was done to prevent services from being initialized multiple times.