chore(docs): Supabase integration docs, and Checkout example#712
Merged
Conversation
thruflo
reviewed
Nov 30, 2023
alco
reviewed
Nov 30, 2023
|
|
||
| Next, we configure Electric to connect to Supabase. The [Electric sync service](../../api/service) is available as either a Docker image or Elixir app, and it uses environment variables for configuration. | ||
|
|
||
| You must configure Electric to use the `direct_writes` mode for inbound transactions, as Supabase does not support the default inbound `logical_replication` mode. This is configured with the `ELECTRIC_INBOUND_MODE` environment variable. |
Member
There was a problem hiding this comment.
The setting has been renamed in my PR (but not yet in the canary Docker image).
Suggested change
| You must configure Electric to use the `direct_writes` mode for inbound transactions, as Supabase does not support the default inbound `logical_replication` mode. This is configured with the `ELECTRIC_INBOUND_MODE` environment variable. | |
| You must configure Electric to use the `direct_writes` mode for inbound transactions, as Supabase does not support the default inbound `logical_replication` mode. This is configured with the `ELECTRIC_WRITE_TO_PG_MODE` environment variable. |
Contributor
There was a problem hiding this comment.
@alco any chance of a new canary image? So we can change this var name?
Member
There was a problem hiding this comment.
@thruflo pushed a new image and updated the variable name in the docs.
|
|
||
| ```bash | ||
| DATABASE_URL=postgresql://user-name:password@db.your-host.supabase.co:port/database-name | ||
| ELECTRIC_INBOUND_MODE=direct_writes |
Member
There was a problem hiding this comment.
Suggested change
| ELECTRIC_INBOUND_MODE=direct_writes | |
| ELECTRIC_WRITE_TO_PG_MODE=direct_writes |
| ```bash | ||
| docker run \ | ||
| -e "DATABASE_URL=postgresql://user-name:password@db.your-host.supabase.co:port/database-name" \ | ||
| -e "ELECTRIC_INBOUND_MODE=direct_writes" \ |
Member
There was a problem hiding this comment.
Suggested change
| -e "ELECTRIC_INBOUND_MODE=direct_writes" \ | |
| -e "ELECTRIC_WRITE_TO_PG_MODE=direct_writes" \ |
alterhuman
reviewed
Dec 1, 2023
thruflo
approved these changes
Dec 1, 2023
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related website PR: https://github.com/electric-sql/website/pull/75