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 logging out of Serverless projects. #163154

Merged
merged 1 commit into from
Aug 11, 2023

Conversation

azasypkin
Copy link
Member

@azasypkin azasypkin commented Aug 4, 2023

Summary

The Serverless MVP project experience will not include support for Single Log-out ("SLO"). This means that the cloud console and Kibana will maintain independent sessions, which must be managed separately. Due to this limitation, the user avatar menu should not feature an explicit "Logout" link, as it could mistakenly suggest that we are terminating their Elastic Session. In reality, we are only invalidating the Kibana session.

This PR replace the existing "Logout" link with a "Close project" link, when in Serverless. This link will invalidate the Kibana session (similar to our current “Logout” link) and redirect the user to their Serverless projects list.

Blocked by: #163379

How to test

Locally

xpack.cloud.id: "foo"
xpack.cloud.base_url: "https://console.qa.cld.elstc.co"
xpack.cloud.projects_url: "/projects"
yarn es snapshot --license trial
yarn start --serverless

MKI

POST {{host}}/api/v1/serverless/projects/elasticsearch
Authorization: ApiKey {{api-key}}
Content-Type: application/json

{
  "name": "xxxx",
  "region_id": "local-k8s",
  "overrides": {
    "kibana": {
      "docker_image": "docker.elastic.co/kibana-ci/kibana-serverless:pr-163154-697c0b749433-arm64"
    }
  }
}

Fixes: #162887

@azasypkin azasypkin added Team:Security Team focused on: Auth, Users, Roles, Spaces, Audit Logging, and more! Feature:Security/Authentication Platform Security - Authentication release_note:skip Skip the PR/issue when compiling release notes backport:skip This commit does not require backporting ci:build-serverless-image blocked labels Aug 4, 2023
@azasypkin azasypkin force-pushed the issue-162887-close-project branch from 226c544 to 8d81cc5 Compare August 10, 2023 12:37
@azasypkin azasypkin removed the blocked label Aug 11, 2023
@azasypkin azasypkin force-pushed the issue-162887-close-project branch from 8d81cc5 to 697c0b7 Compare August 11, 2023 08:02
@kibana-ci
Copy link
Collaborator

kibana-ci commented Aug 11, 2023

💛 Build succeeded, but was flaky

  • Buildkite Build
  • Commit: 697c0b7
  • Kibana Serverless Image: docker.elastic.co/kibana-ci/kibana-serverless:pr-163154-697c0b749433

Failed CI Steps

Metrics [docs]

Canvas Sharable Runtime

The Canvas "shareable runtime" is an bundle produced to enable running Canvas workpads outside of Kibana. This bundle is included in third-party webpages that embed canvas and therefor should be as slim as possible.

id before after diff
module count - 5381 +5381
total size - 6.0MB +6.0MB

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
security 69.7KB 70.0KB +271.0B

History

  • 💛 Build #149180 was flaky 8d81cc5e0a75a05745cecd1b18b2009cfdbebb2f
  • 💔 Build #147464 failed 226c54471b20c417d1957eefcfe565195f795d2d

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

@azasypkin azasypkin marked this pull request as ready for review August 11, 2023 09:28
@azasypkin azasypkin requested a review from a team as a code owner August 11, 2023 09:28
@elasticmachine
Copy link
Contributor

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

Copy link
Contributor

@thomheymann thomheymann left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good and all working as expected.

I have tested this with idle timeout as well and am being redirected to the cloud projects page as expected. 👌

@azasypkin azasypkin merged commit 987a850 into elastic:main Aug 11, 2023
@azasypkin azasypkin deleted the issue-162887-close-project branch August 11, 2023 14:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting ci:build-serverless-image Feature:Security/Authentication Platform Security - Authentication release_note:skip Skip the PR/issue when compiling release notes Team:Security Team focused on: Auth, Users, Roles, Spaces, Audit Logging, and more! v8.10.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support logging out of projects
5 participants