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 referenceAuth with only user pool, create new identity pool, roles, user pool client #2252

Open
josefaidt opened this issue Nov 20, 2024 · 1 comment
Labels
auth Issue pertaining to Amplify Auth feature-request New feature or request

Comments

@josefaidt
Copy link
Contributor

Environment information

n/a

Describe the feature

lifting this comment from the referenceAuth RFC into its own feature request
#1548 (comment)

Scenario:

  1. We deploy App1 and with it a UserPool, IdentityPool, and UserPoolClient. The app matures and accumulates users.
  2. We conceive of some new functionality that is related to App1 but not exactly the same app. So we deploy App2 that offers the same user base new functionality. App1 and App2 are separate enough that they should not be rolled into one deployment and have different release cycles.
  3. We want to reuse the UserPool in App1 since both apps are used by the same users...however we want to create a new IdentityPool and a new UserPoolClient for App2.
// amplify/auth/resource.ts
import { referenceAuth } from "@aws-amplify/backend"

export const auth = referenceAuth({
  userPoolId: "...",
})

Referencing by only the user pool ID will create new resources:

  • identity pool
  • authenticated role
  • unauthenticated role
  • user pool client

Each of these new resources will enable scoping policies to only interact with resources within the Amplify app

Use case

see above

@josefaidt josefaidt added the pending-triage Incoming issues that need categorization label Nov 20, 2024
@ykethan
Copy link
Member

ykethan commented Nov 20, 2024

Marking as feature request.

@ykethan ykethan added feature-request New feature or request auth Issue pertaining to Amplify Auth and removed pending-triage Incoming issues that need categorization labels Nov 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auth Issue pertaining to Amplify Auth feature-request New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants