You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Sep 8, 2021. It is now read-only.
The FAUNADB_SECRET was needed to create the table in faunadb, but I only got unauthorized errors when running the app. Looking in the code I found it is using the FAUNADB_SERVER_SECRET environment variable to actually make the calls, once I set that as well then the application ran and I could create todo entries. The functions/todos-real-all.js contains the following code for example.
const client = new faunadb.Client({
secret: process.env.FAUNADB_SERVER_SECRET
})
Easy fix is to set both env variables (e.g. in windows):
set FAUNADB_SECRET= (admin key)
set FAUNADB_SERVER_SECRET= (server key)
So all that is needed is for the tutorial to be updated to instruct both environmental variables to be set. First time using netlify and first time using faunadb so good if it works out of the box as a good demo.
The text was updated successfully, but these errors were encountered:
Uh oh!
There was an error while loading. Please reload this page.
The FAUNADB_SECRET was needed to create the table in faunadb, but I only got unauthorized errors when running the app. Looking in the code I found it is using the FAUNADB_SERVER_SECRET environment variable to actually make the calls, once I set that as well then the application ran and I could create todo entries. The functions/todos-real-all.js contains the following code for example.
const client = new faunadb.Client({
secret: process.env.FAUNADB_SERVER_SECRET
})
Easy fix is to set both env variables (e.g. in windows):
set FAUNADB_SECRET= (admin key)
set FAUNADB_SERVER_SECRET= (server key)
The keys were set at the in the fauna cloud dashboard: https://dashboard.fauna.com/keys/@db/
So all that is needed is for the tutorial to be updated to instruct both environmental variables to be set. First time using netlify and first time using faunadb so good if it works out of the box as a good demo.
The text was updated successfully, but these errors were encountered: