Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions apps/cli/src/shared/init/project-init.templates.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ port = 54321
schemas = ["public", "graphql_public"]
# Extra schemas to add to the search_path of every request.
extra_search_path = ["public", "extensions"]
# The maximum number of rows returns from a view, table, or stored procedure. Limits payload size
# The maximum number of rows returned from a view, table, or stored procedure. Limits payload size
# for accidental or malicious requests.
max_rows = 1000
# Controls whether new tables, views, sequences and functions created in the \`public\` schema by
Expand Down Expand Up @@ -339,11 +339,15 @@ skip_nonce_check = false
# If enabled, it will allow the user to successfully authenticate when the provider does not return an email address.
email_optional = false

# Allow Solana wallet holders to sign in to your project via the Sign in with Solana (SIWS, EIP-4361) standard.
# Allow Solana wallet holders to sign in to your project via the Sign in with Solana (SIWS) standard.
# You can configure "web3" rate limit in the [auth.rate_limit] section and set up [auth.captcha] if self-hosting.
[auth.web3.solana]
enabled = false

# Allow Ethereum wallet holders to sign in to your project via the Sign in with Ethereum (SIWE, EIP-4361) standard.
# [auth.web3.ethereum]
# enabled = true

# Use Firebase Auth as a third-party provider alongside Supabase Auth.
[auth.third_party.firebase]
enabled = false
Expand Down
16 changes: 15 additions & 1 deletion apps/cli/src/shared/init/project-init.templates.unit.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,14 +65,28 @@ const NATIVE_AUTO_EXPOSE_COMMENT = `# without explicit GRANTs, matching the clou
# instead. Left unset, a fresh project falls back to \`true\`.
# auto_expose_new_tables = true`;

/* Only the native template documents Ethereum web3, cites SIWS without EIP-4361 and fixes
the `max_rows` comment typo; the vendored scaffold is left as shipped. */
const NATIVE_WEB3_ETHEREUM_EXAMPLE = `
# Allow Ethereum wallet holders to sign in to your project via the Sign in with Ethereum (SIWE, EIP-4361) standard.
# [auth.web3.ethereum]
# enabled = true
`;

const renderExpectedNativeEject = renderExpectedGoEject.pipe(
Effect.map((eject) =>
eject
.replace(
'# content_path = "./templates/password_changed_notification.html"',
'# content_path = "./supabase/templates/password_changed_notification.html"',
)
.replace(GO_AUTO_EXPOSE_COMMENT, NATIVE_AUTO_EXPOSE_COMMENT),
.replace(GO_AUTO_EXPOSE_COMMENT, NATIVE_AUTO_EXPOSE_COMMENT)
.replace("rows returns from", "rows returned from")
.replace("(SIWS, EIP-4361)", "(SIWS)")
.replace(
"[auth.web3.solana]\nenabled = false\n",
`[auth.web3.solana]\nenabled = false\n${NATIVE_WEB3_ETHEREUM_EXAMPLE}`,
),
),
);

Expand Down
Loading