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

Scratch Org From Snapshot - Copied with failing Connected App, but without certificates #3179

Open
pkozuchowski opened this issue Jan 15, 2025 · 3 comments
Labels
more information required Issue requires more information or a response from the customer

Comments

@pkozuchowski
Copy link

Summary

When scratch org is created from Scratch Org Snapshot, new scratch org contains Connected App. Any interaction with this app leads to Internal Server Error
image

At the same time, the scratch org is not copied with certificates, which I think provides value compared to Connected App:

  • When you are building project that relies on external API and authorize through JWT, you have to generate private key in Salesforce and upload public key in the API platform. It's a problem for scratch orgs, since they are temporary and either you have to spam API team with new public keys for every scratch org, or have exportable cert on long living org and import that.
    If snapshot were copied with certs, the process becomes trivial - we are setting up certificate on snapshot and all scratch orgs are good to go right away. It's much safer, because the private keys is never touched by human hands.

Steps To Reproduce

  1. Create Scratch org which will be used as snapshot
  2. Create Connected App
  3. Create Self-Signed Certificate
  4. Create scratch org snapshot from this org
  5. Create new scratch org from the snapshot
  6. Observe that it has Connected App and it's failing with internal error and certificate is gone.
@pkozuchowski pkozuchowski added the investigating We're actively investigating this issue label Jan 15, 2025
Copy link

Thank you for filing this issue. We appreciate your feedback and will review the issue as soon as possible. Remember, however, that GitHub isn't a mechanism for receiving support under any agreement or SLA. If you require immediate assistance, contact Salesforce Customer Support.

Copy link

Hello @pkozuchowski 👋 It looks like you didn't include the full Salesforce CLI version information in your issue.
Please provide the output of version --verbose --json for the CLI you're using (sf or sfdx).

A few more things to check:

  • Make sure you've provided detailed steps to reproduce your issue.
    • A repository that clearly demonstrates the bug is ideal.
  • Make sure you've installed the latest version of Salesforce CLI. (docs)
    • Better yet, try the rc or nightly versions. (docs)
  • Try running the doctor command to diagnose common issues.
  • Search GitHub for existing related issues.

Thank you!

@github-actions github-actions bot added more information required Issue requires more information or a response from the customer and removed investigating We're actively investigating this issue labels Jan 15, 2025
@pkozuchowski
Copy link
Author

pkozuchowski commented Jan 15, 2025

FYI: Due to remote desktop policies, I cannot upgrade node, so I'm skipping tech details section - otherwise bot will close my issue.
This occurs on latest SF CLI version and I doubt node has anything to do with the issue :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
more information required Issue requires more information or a response from the customer
Projects
None yet
Development

No branches or pull requests

1 participant