-
Notifications
You must be signed in to change notification settings - Fork 142
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(electric)!: Change some configuration options name for better DX (
#305) This is related to the documentation changes discussed in electric-sql/legacy-website#29.
- Loading branch information
Showing
14 changed files
with
163 additions
and
146 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
--- | ||
"@core/electric": patch | ||
--- | ||
|
||
Make some configuration option names more descriptive. Namely, | ||
|
||
- rename `ELECTRIC_HOST` to `LOGICAL_PUBLISHER_HOST` | ||
- rename `POSTGRES_REPLICATION_PORT` to `LOGICAL_PUBLISHER_PORT` | ||
- rename `STATUS_PORT` to `HTTP_API_PORT` | ||
|
||
The first two options together define the host:port pair that the PostgreSQL database will connect to | ||
in order to start following Electric's logical replication stream that publishes inbound changes from all clients. | ||
|
||
The `HTTP_API_PORT` option is now more aptly named since Electric exposes more than just the status endpoint | ||
on that port. |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,7 @@ ARG BUILDER_IMAGE="hexpm/elixir:${ELIXIR_VERSION}-erlang-${OTP_VERSION}-debian-$ | |
ARG RUNNER_IMAGE="debian:${DEBIAN_VERSION}" | ||
|
||
FROM ${BUILDER_IMAGE} AS builder | ||
LABEL maintainer="[email protected]" | ||
LABEL maintainer="[email protected]" | ||
|
||
RUN apt-get update -y && \ | ||
apt-get install -y build-essential git curl && \ | ||
|
@@ -20,12 +20,12 @@ ENV MIX_ENV=prod | |
WORKDIR /app | ||
COPY Makefile /app/ | ||
|
||
COPY mix.* /app/ | ||
COPY mix.* /app/ | ||
RUN mix deps.get | ||
COPY config/config.exs config/prod.exs /app/config/ | ||
COPY config/config.exs /app/config/ | ||
RUN mix deps.compile | ||
|
||
COPY lib /app/lib/ | ||
COPY lib /app/lib/ | ||
COPY config/*runtime.exs /app/config/ | ||
|
||
ARG ELECTRIC_VERSION=local | ||
|
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,43 +1,3 @@ | ||
# This file is responsible for configuring your application | ||
# and its dependencies with the aid of the Mix.Config module. | ||
# | ||
# This configuration file is loaded before any dependency and | ||
# is restricted to this project. | ||
|
||
# General application configuration | ||
import Config | ||
|
||
# Configures Elixir's Logger | ||
config :logger, :console, | ||
format: "$time $metadata[$level] $message\n", | ||
metadata: [ | ||
:connection, | ||
:origin, | ||
:pid, | ||
:pg_client, | ||
:pg_producer, | ||
:pg_slot, | ||
:sq_client, | ||
:component, | ||
:instance_id, | ||
:client_id, | ||
:user_id, | ||
:metadata | ||
] | ||
|
||
config :logger, | ||
handle_otp_reports: true, | ||
handle_sasl_reports: false, | ||
level: :debug | ||
|
||
config :electric, Electric.Replication.Postgres, | ||
pg_client: Electric.Replication.Postgres.Client, | ||
producer: Electric.Replication.Postgres.LogicalReplicationProducer | ||
|
||
config :electric, Electric.Postgres.CachedWal.Api, adapter: Electric.Postgres.CachedWal.EtsBacked | ||
|
||
config :electric, Electric.StatusPlug, port: 5050 | ||
|
||
# Import environment specific config. This must remain at the bottom | ||
# of this file so it overrides the configuration defined above. | ||
import_config "#{config_env()}.exs" |
This file was deleted.
Oops, something went wrong.
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import Config | ||
|
||
alias Electric.Satellite.Auth | ||
|
||
auth_config = | ||
Auth.Secure.build_config!( | ||
alg: "HS256", | ||
key: "test-signing-key-at-least-32-bytes-long", | ||
iss: "electric-sql-test-issuer" | ||
) | ||
|
||
config :electric, Electric.Satellite.Auth, provider: {Auth.Secure, auth_config} | ||
|
||
config :electric, Electric.Replication.OffsetStorage, file: "./offset_storage_data.test.dat" |
This file was deleted.
Oops, something went wrong.
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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