Skip to content
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

Support setting up Kibana spaces declaratively. #127286

Open
scbjans opened this issue Feb 17, 2022 · 6 comments
Open

Support setting up Kibana spaces declaratively. #127286

scbjans opened this issue Feb 17, 2022 · 6 comments
Labels
enhancement New value added to drive a business result Feature:Security/Spaces Platform Security - Spaces feature Team:Security Team focused on: Auth, Users, Roles, Spaces, Audit Logging, and more!

Comments

@scbjans
Copy link

scbjans commented Feb 17, 2022

Proposal

Support setting up Kibana spaces declaratively.

Use case. Why is this important?

Using ECK it is possible to set up custom users and roles using file realm.

When a role is restricted to a specific Kibana Space; the space still has to be created manually.
Once the space is created, the user (mapped to that role) can be used.

It would be helpful if Kibana spaces can be configured using a spaces.yml file (similar to custom roles in roles.yml)

@botelastic botelastic bot added the triage label Feb 17, 2022
@thbkrkr
Copy link
Contributor

thbkrkr commented Feb 17, 2022

Somewhat related to elastic/cloud-on-k8s#3598 but for Kibana, if spaces were created using the Kibana Spaces API.

@thbkrkr
Copy link
Contributor

thbkrkr commented Mar 9, 2022

It would be helpful if Kibana spaces can be configured using a spaces.yml file (similar to custom roles in roles.yml)

It would be necessary to start by having the feature in Kibana so that ECK can use it, which is not the case currently. AFAIK there is currently only an HTTP API to manage Spaces.

Let's move the issue to discuss with the Kibana team to see if this is something that might make sense.

@thbkrkr thbkrkr transferred this issue from elastic/cloud-on-k8s Mar 9, 2022
@botelastic botelastic bot added the needs-team Issues missing a team label label Mar 9, 2022
@oneingan
Copy link

@rayafratkina rayafratkina added the Team:Security Team focused on: Auth, Users, Roles, Spaces, Audit Logging, and more! label May 26, 2022
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-security (Team:Security)

@botelastic botelastic bot removed the needs-team Issues missing a team label label May 26, 2022
@jportner jportner added enhancement New value added to drive a business result Feature:Security/Spaces Platform Security - Spaces feature and removed triage labels May 28, 2022
@legrego
Copy link
Member

legrego commented May 31, 2022

I have a couple of questions around expected functionality:

  1. Would the presence of file-based spaces prevent users from creating/updating/deleting spaces via the UI? Or would it mark the file-based spaces as "readonly", and allow for the creation of other spaces via UI?
  2. What happens when a space is removed from the file? Should we delete the space, and all associated saved objects?
  3. I'd expect we would need to document the fact that file-based spaces need to be kept in sync across all Kibana instances -- a mismatch here would leave Kibana in a non-deterministic state. Do you agree?

@scbjans
Copy link
Author

scbjans commented Jun 3, 2022

From a functional point of view I would expect it to work similarly to the already existing roles.yml. I'm not sure how my below answers fit to that, but for the sake of standardization, I think resembling roles.yml should be prioritized more than my answers.

My $0.02:

  1. I would expect all spaces will be managed through spaces.yml; so creating/updating/deleting spaces via the UI should not be possible.
  2. From a declarative point of view, I think deleting a space from the file, should also remove the space and it's associated objects.
  3. This issue was created particularly for use with ECK. Since I think it will probably be mounted as a secret (just like when defining roles declaratively), kubernetes will make sure it's in sync between all pods. I'm not sure how it will behave in other cases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New value added to drive a business result Feature:Security/Spaces Platform Security - Spaces feature Team:Security Team focused on: Auth, Users, Roles, Spaces, Audit Logging, and more!
Projects
None yet
Development

No branches or pull requests

7 participants