Skip to content

Conversation

@martinschaer
Copy link
Contributor

@martinschaer martinschaer commented Jan 1, 2023

☕️ Reasoning

Adding a SurrealDB adapter.

🧢 Checklist

  • Documentation
  • Tests
  • Ready to be merged

🎫 Affected issues

Fixes: INSERT_ISSUE_LINK_HERE

@vercel
Copy link

vercel bot commented Jan 1, 2023

Someone is attempting to deploy a commit to the authjs Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions github-actions bot added the adapters Changes related to the core code concerning database adapters label Jan 1, 2023
@balazsorban44 balazsorban44 force-pushed the main branch 6 times, most recently from 19c6807 to 3be7bb7 Compare January 7, 2023 08:50
@Sacramentix
Copy link
Contributor

I'm gonna test this today, thanks for the contribution. :)

@martinschaer
Copy link
Contributor Author

@Sacramentix thanks! I added it to a side-project hosted on vercel (nextjs) with SurrealDB on AWS Fargate + EFS. It works well for a 1 minute, then I get logged out… If I try to log in again I get this error "Try signing in with a different account". If I try after a while it works back again. Running it locally works fine. I haven't had the time to debug this, hopefully today or tomorrow.

This PR is in draft since I haven't added the documentation in the README.

@vercel
Copy link

vercel bot commented Jan 13, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
auth-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Sep 23, 2023 1:34pm
1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
next-auth-docs ⬜️ Ignored (Inspect) Visit Preview Sep 23, 2023 1:34pm

@hgoona
Copy link

hgoona commented Jan 26, 2023

Hey team! I don't know to formally contribute to these but I just managed to get the above adaptor working with a the new AuthJS for Sveltekit - with some minor tweaks, setup in the "Sveltekit" way.

Took a long time to figure it out so I documented it here (along with my noob struggles/errors): https://gist.github.com/hgoona/ad5d6fcfa446a7a56b29a977861747eb

Hope the code structure can be useful to other Sveltekit / AuthJs / SurrealDB users! 💪🏾

^consider my above as a "test" to vouch for @martinschaer work👏🏾👏🏾👏🏾

@rvdende
Copy link

rvdende commented Sep 18, 2023

Hi all, I'm wondering if there is a possibility of adding surrealdb scope authentication to this? The idea being that an authenticated user can then access the database from the frontend directly.

@ThangHuuVu ThangHuuVu merged commit bec01a8 into nextauthjs:main Sep 23, 2023
@ThangHuuVu
Copy link
Member

@rvdende can you open a separate discussion for your question? 🙏

@var-che
Copy link

var-che commented Sep 30, 2023

Is the installation/setup page for surrealDB going to be updated? Right now, the adapter page is empty.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

adapters Changes related to the core code concerning database adapters enhancement New feature or request typeorm-legacy

Projects

None yet

Development

Successfully merging this pull request may close these issues.