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

Create dedicated OAuthclient #658

Merged
merged 1 commit into from
Oct 24, 2022
Merged

Create dedicated OAuthclient #658

merged 1 commit into from
Oct 24, 2022

Conversation

samuelvl
Copy link
Contributor

@samuelvl samuelvl commented Oct 11, 2022

Description

Fix #479

How Has This Been Tested?

Install the opendatahub-operator and patch the CSV image:

$ oc edit csv opendatahub-operator.v1.3.0 -n openshift-operator
...
326                 image: quay.io/opendatahub/opendatahub-operator:v1.3.0 -> quay.io/vhire/opendatahub-operator:testoauth
...

Edit the .env file to use the following image:

IMAGE_REPOSITORY=quay.io/samuvl/odh-dashboard:oauth-client

Run make deploy and wait until the dashboard is deployed and running:

$ oc get pods -l app=odh-dashboard -n opendatahub
NAME                             READY   STATUS    RESTARTS   AGE
odh-dashboard-5fbc469d8c-6j7dj   2/2     Running   0          4m9s
odh-dashboard-5fbc469d8c-dbf5w   2/2     Running   0          4m9s
odh-dashboard-5fbc469d8c-pcvpb   2/2     Running   0          4m9s
odh-dashboard-5fbc469d8c-rrtws   2/2     Running   0          4m9s
odh-dashboard-5fbc469d8c-w2lgz   2/2     Running   0          4m9s

Verify the OAuthClient object is created with the correct information:

$ oc get oauthclient dashboard-oauth-client -o yaml             
apiVersion: oauth.openshift.io/v1
grantMethod: auto
kind: OAuthClient
metadata:
  creationTimestamp: "2022-10-24T09:06:00Z"
  name: dashboard-oauth-client
  resourceVersion: "46725569"
  uid: 251c4c25-c123-4eaf-bc1a-1b96e07a5b9e
redirectURIs:
- https://odh-dashboard-opendatahub.apps.samuvl-odh.mydomain.com
secret: jPlOar1OaoWWiVWoDgDRElvpytyGMnf1

Merge criteria:

  • The commits are squashed in a cohesive manner and have meaningful messages.
  • Testing instructions have been added in the PR body (for PRs involving changes that are not immediately obvious).
  • The developer has manually tested the changes and verified that the changes work

@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress This PR is in WIP state label Oct 11, 2022
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 11, 2022

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@samuelvl
Copy link
Contributor Author

samuelvl commented Oct 11, 2022

Draft until opendatahub-operator 1.4 is released to include opendatahub-io/opendatahub-operator#177

fyi @andrewballantyne @lucferbux

@andrewballantyne
Copy link
Member

@samuelvl I think this looks to fix this one too -- no? #337

@samuelvl
Copy link
Contributor Author

@andrewballantyne Correct, operator 1.4 release will allow me to mark both PRs as ready.

@andrewballantyne
Copy link
Member

@andrewballantyne Correct, operator 1.4 release will allow me to mark both PRs as ready.

Oh I see -- so this one PR won't handle both -- ah okay, thanks for the update.

@samuelvl samuelvl marked this pull request as ready for review October 21, 2022 14:49
@openshift-ci openshift-ci bot removed the do-not-merge/work-in-progress This PR is in WIP state label Oct 21, 2022
@openshift-ci openshift-ci bot requested review from LaVLaS and maroroman October 21, 2022 14:49
@samuelvl samuelvl requested review from lucferbux and andrewballantyne and removed request for LaVLaS and maroroman October 21, 2022 14:50
Copy link
Member

@andrewballantyne andrewballantyne left a comment

Choose a reason for hiding this comment

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

/hold

@openshift-ci openshift-ci bot added do-not-merge/hold This PR is hold for some reason lgtm approved labels Oct 21, 2022
@andrewballantyne andrewballantyne linked an issue Oct 21, 2022 that may be closed by this pull request
Copy link
Member

@cfchase cfchase left a comment

Choose a reason for hiding this comment

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

/lgtm

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 24, 2022

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: andrewballantyne, cfchase

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@andrewballantyne andrewballantyne removed the do-not-merge/hold This PR is hold for some reason label Oct 24, 2022
@openshift-merge-robot openshift-merge-robot merged commit 0201a38 into opendatahub-io:f/dsg Oct 24, 2022
openshift-merge-robot pushed a commit that referenced this pull request Oct 31, 2022
* Add empty DSG page & nav (#471)

* Add empty DSG page & nav

* Rework the way navs work & add feature flag

* Kubernetes Pass Through API & SDK Initialization (#279)

* SDK npm installed

* Pass-through api & SDK setup

* Migrated ConfigMap, Secret, PVC to SDK calls

* Adjust k8s pass through to handle bad create urls

* Code cleanup

* Add local dev token & header access token support

* Remove v12 from the supported node-versions

* Fix test issue & convert starting notebook to SDK call

* Added some docs and fixed a type issue

* Address a couple issues with the flow

* Improve server logging

* Misc cleanup of DSG (#481)

* Add project view details page (#578)

* Add project view details page

* address comment

* make jumplink items generic

* modify type

* small fixes

* Create projects (#597)

* Create projects

* Added workaround for self signed certs

* List Projects & Delete Project (#605)

* List of Projects with Notebook Details

* Make Notebooks have display annotations

* Pagination and filter

* Handle pagination edge cases

* Edit projects

* Improve edit modal data management

* Delete project

* Add an filterd empty row

* Cleaned up projects to be more organized & fixed issue with 404 project

* Add a watcher for when starting the notebook via toggle

* Add bad certif workaround to debug script

* Create add storage modal (#582)

* Create add storage modal

* refactor files

* clean up import

* fix layout of existing storage

* pass less props

* address comments

* Add part of spawner page (#610)

* Add part of spawner page

* add creating notebook

* fix small issues

* Add storage section for spawner page (#637)

* Workspace Table (#660)

* Follow up fix for #610 and #637 (#664)

* follow up fix for #610

* follow up PR #637

* clean up

* Code cleanup (#665)

* Cleanup of Spawner code

* Update the image details in the workspaces table

* Add storage list layout (#666)

* Add storage list layout

* address comments

* make JSX and functions inline

* Data Connections List (#671)

* Stop Notebook Confirmation Modal (#672)

* Delete Notebook Modal (#673)

* Delete Notebook Modal

* Refresh only if finished deleting

* Spawner Environment Section (#670)

* Added spawner page.

Refactor code part 1.

Refactor secret and config map.

Added upload code.

Fixed style issues.

* Refactored code.

* Disabled AWS.

* Updated pass through code.

* Fixed linting errors.

* Removed some dead code.

AWS update.

updates to secret


Reverted code.

* Fixed linting errors.

* Delete Storage Modal (#677)

* Prometheus connection for inUse storage value (#676)

* Added spawner page. (#679)

Refactor code part 1.

Refactor secret and config map.

Added upload code.

Fixed style issues.

Refactored code.

Disabled AWS.

Updated pass through code.

Fixed linting errors.

Removed some dead code.

AWS update.

updates to secret

Added AWS code.

Fixed rebase files.

Fixed linting errors.

* Cleanup Random DSG stuff (#678)

* Added breadcrumb for project details and spawner page. (#682)

* Adjust Storage based on UX input (#684)

* Add status tooltip and start notebook modal (#683)

* Add status tooltip and start notebook modal

* get projectName from notebook namespace

* Environment Spawner Section & Data Connections (#688)

* Cleanup lint issues

* Create dedicated OAuthclient (#658)

* DSG Fixes (#696)

* Source all the details data from the same spot

* Connected Workspaces now pull from context

* Follow-up fix for DSG work (#695)

* bug fixes for dsg

* rebase

* Refresh notebook status and fetch all status periodically (#697)

* refresh notebook status and fetch all status periodically

* small fix for listening notebook

* some rename and clean up

* add input group for mount path and change placeholder text

* refactor useRelatedNotebooks

* Improve storage section features and bug fix (#698)

* use config pvs size and some small bug fix

* storage part refactor

* add check for terminated status

* Add ability to delete attached PVC (#699)

* Add ability to delete attached PVC

* add inline for alert

* Improve Project Creation & Data Connection Modal (#700)

* Misc DSG Fixes

* Projects creation flexibility & data connection functionality

* Fixes for DSG (#701)

* update storage name and description

* add aria-label and id on spawner page and project details page

* add data-label for table cells

* add GPU field and remove secure route for backend GPU

* add generic delete modal

* Translate display names into k8s names (#702)

* Translate display names into k8s names

* Minor changes to text and support a more direct delete button text

* Fix lint issue

* Fixes and features for DSG (#704)

* delete data connection will also delete envFrom field

* change switch to separate text and switch button

* indent data connection list

* make data connection name sortable

* sort notebooks by status

* change select menuAppendTo on spawner page

* add truncate for dependency package details

* make table show expand style correctly

* clean up dependencies

* add label to all the resources created by dashboard

* UX Feedback -- DSG Changes (#705)

* Add icon & tooltip for k8s resource identification

* Allow searching on user associated to Projects

* Improved tooltips and added more to the project creation

* Add generic padding to the bottom of the scrollable content

* Cleanup delete modal as it closes

* Updated UX wording

* Edit Notebook

* Realign tooltip -- removeFindDomNode issue

* Fix lint issues

Co-authored-by: Juntao Wang <37624318+DaoDaoNoCode@users.noreply.github.com>
Co-authored-by: Donald Labaj <dlabaj@redhat.com>
Co-authored-by: Samu <svelosol@redhat.com>
strangiato pushed a commit to strangiato/odh-dashboard that referenced this pull request Oct 18, 2023
* Add empty DSG page & nav (opendatahub-io#471)

* Add empty DSG page & nav

* Rework the way navs work & add feature flag

* Kubernetes Pass Through API & SDK Initialization (opendatahub-io#279)

* SDK npm installed

* Pass-through api & SDK setup

* Migrated ConfigMap, Secret, PVC to SDK calls

* Adjust k8s pass through to handle bad create urls

* Code cleanup

* Add local dev token & header access token support

* Remove v12 from the supported node-versions

* Fix test issue & convert starting notebook to SDK call

* Added some docs and fixed a type issue

* Address a couple issues with the flow

* Improve server logging

* Misc cleanup of DSG (opendatahub-io#481)

* Add project view details page (opendatahub-io#578)

* Add project view details page

* address comment

* make jumplink items generic

* modify type

* small fixes

* Create projects (opendatahub-io#597)

* Create projects

* Added workaround for self signed certs

* List Projects & Delete Project (opendatahub-io#605)

* List of Projects with Notebook Details

* Make Notebooks have display annotations

* Pagination and filter

* Handle pagination edge cases

* Edit projects

* Improve edit modal data management

* Delete project

* Add an filterd empty row

* Cleaned up projects to be more organized & fixed issue with 404 project

* Add a watcher for when starting the notebook via toggle

* Add bad certif workaround to debug script

* Create add storage modal (opendatahub-io#582)

* Create add storage modal

* refactor files

* clean up import

* fix layout of existing storage

* pass less props

* address comments

* Add part of spawner page (opendatahub-io#610)

* Add part of spawner page

* add creating notebook

* fix small issues

* Add storage section for spawner page (opendatahub-io#637)

* Workspace Table (opendatahub-io#660)

* Follow up fix for opendatahub-io#610 and opendatahub-io#637 (opendatahub-io#664)

* follow up fix for opendatahub-io#610

* follow up PR opendatahub-io#637

* clean up

* Code cleanup (opendatahub-io#665)

* Cleanup of Spawner code

* Update the image details in the workspaces table

* Add storage list layout (opendatahub-io#666)

* Add storage list layout

* address comments

* make JSX and functions inline

* Data Connections List (opendatahub-io#671)

* Stop Notebook Confirmation Modal (opendatahub-io#672)

* Delete Notebook Modal (opendatahub-io#673)

* Delete Notebook Modal

* Refresh only if finished deleting

* Spawner Environment Section (opendatahub-io#670)

* Added spawner page.

Refactor code part 1.

Refactor secret and config map.

Added upload code.

Fixed style issues.

* Refactored code.

* Disabled AWS.

* Updated pass through code.

* Fixed linting errors.

* Removed some dead code.

AWS update.

updates to secret


Reverted code.

* Fixed linting errors.

* Delete Storage Modal (opendatahub-io#677)

* Prometheus connection for inUse storage value (opendatahub-io#676)

* Added spawner page. (opendatahub-io#679)

Refactor code part 1.

Refactor secret and config map.

Added upload code.

Fixed style issues.

Refactored code.

Disabled AWS.

Updated pass through code.

Fixed linting errors.

Removed some dead code.

AWS update.

updates to secret

Added AWS code.

Fixed rebase files.

Fixed linting errors.

* Cleanup Random DSG stuff (opendatahub-io#678)

* Added breadcrumb for project details and spawner page. (opendatahub-io#682)

* Adjust Storage based on UX input (opendatahub-io#684)

* Add status tooltip and start notebook modal (opendatahub-io#683)

* Add status tooltip and start notebook modal

* get projectName from notebook namespace

* Environment Spawner Section & Data Connections (opendatahub-io#688)

* Cleanup lint issues

* Create dedicated OAuthclient (opendatahub-io#658)

* DSG Fixes (opendatahub-io#696)

* Source all the details data from the same spot

* Connected Workspaces now pull from context

* Follow-up fix for DSG work (opendatahub-io#695)

* bug fixes for dsg

* rebase

* Refresh notebook status and fetch all status periodically (opendatahub-io#697)

* refresh notebook status and fetch all status periodically

* small fix for listening notebook

* some rename and clean up

* add input group for mount path and change placeholder text

* refactor useRelatedNotebooks

* Improve storage section features and bug fix (opendatahub-io#698)

* use config pvs size and some small bug fix

* storage part refactor

* add check for terminated status

* Add ability to delete attached PVC (opendatahub-io#699)

* Add ability to delete attached PVC

* add inline for alert

* Improve Project Creation & Data Connection Modal (opendatahub-io#700)

* Misc DSG Fixes

* Projects creation flexibility & data connection functionality

* Fixes for DSG (opendatahub-io#701)

* update storage name and description

* add aria-label and id on spawner page and project details page

* add data-label for table cells

* add GPU field and remove secure route for backend GPU

* add generic delete modal

* Translate display names into k8s names (opendatahub-io#702)

* Translate display names into k8s names

* Minor changes to text and support a more direct delete button text

* Fix lint issue

* Fixes and features for DSG (opendatahub-io#704)

* delete data connection will also delete envFrom field

* change switch to separate text and switch button

* indent data connection list

* make data connection name sortable

* sort notebooks by status

* change select menuAppendTo on spawner page

* add truncate for dependency package details

* make table show expand style correctly

* clean up dependencies

* add label to all the resources created by dashboard

* UX Feedback -- DSG Changes (opendatahub-io#705)

* Add icon & tooltip for k8s resource identification

* Allow searching on user associated to Projects

* Improved tooltips and added more to the project creation

* Add generic padding to the bottom of the scrollable content

* Cleanup delete modal as it closes

* Updated UX wording

* Edit Notebook

* Realign tooltip -- removeFindDomNode issue

* Fix lint issues

Co-authored-by: Juntao Wang <37624318+DaoDaoNoCode@users.noreply.github.com>
Co-authored-by: Donald Labaj <dlabaj@redhat.com>
Co-authored-by: Samu <svelosol@redhat.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[DSG]: Fix On-Cluster K8s Pass Through
4 participants