Skip to content

Commit

Permalink
[dashboard] help github users with org restrictions (gitpod-io#19700)
Browse files Browse the repository at this point in the history
  • Loading branch information
svenefftinge authored May 7, 2024
1 parent bc05c69 commit ad9633b
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions components/dashboard/src/workspaces/CreateWorkspacePage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ import { useAllowedWorkspaceClassesMemo } from "../data/workspaces/workspace-cla
import Menu from "../menu/Menu";
import { useOrgSettingsQuery } from "../data/organizations/org-settings-query";
import { useAllowedWorkspaceEditorsMemo } from "../data/ide-options/ide-options-query";
import { isGitpodIo } from "../utils";

type NextLoadOption = "searchParams" | "autoStart" | "allDone";

Expand Down Expand Up @@ -746,6 +747,15 @@ export const RepositoryNotFound: FC<{ error: StartWorkspaceError }> = ({ error }
/>
);
}
if (authProvider.id.toLocaleLowerCase() === "public-github" && isGitpodIo()) {
return (
<RepositoryInputError
title={`Although you appear to have the correct authorization credentials, the '${owner}' organization has enabled OAuth App access restrictions, meaning that data access to third-parties is limited. For more information on these restrictions, including how to enable this app, visit https://docs.github.com/articles/restricting-access-to-your-organization-s-data/.`}
linkText="Check Organization Permissions"
linkHref={"https://github.com/settings/connections/applications/484069277e293e6d2a2a"}
/>
);
}

return (
<RepositoryInputError
Expand Down

0 comments on commit ad9633b

Please sign in to comment.