jochen
908d45864a
supabase: make logflare's stored key and backends follow its environment
...
logflare 1.4.0 copies LOGFLARE_API_KEY into its default user and
POSTGRES_BACKEND_URL into every source's backend once, when it creates
them, and never reads either again. On ace every source still points at
db:5432, which resolves nowhere, so analytics stored no logs; and the key
that leaked into the log before #85 could not be replaced, because the
mesh had to mark it "applied".
The start script now runs logflare's migrations and then reconcile.exs
through `logflare eval`, before logflare starts: it uses logflare's own
Users and Backends contexts to set the default user's key to
LOGFLARE_API_KEY (clearing old_api_key) and to point each postgres
source backend at POSTGRES_BACKEND_URL. It changes nothing that already
matches, says what it changed without printing the key or a password,
and stops the start when it cannot finish.
With the key taken at every start, the secret is "at-start" and `secret
rotate` works. analytics restarts on its env file and studio on its env
file too, so a rotated key reaches every reader.
2026-10-06 11:48:57 +02:00
..
2026-10-04 13:21:47 +02:00
2026-10-05 10:11:27 +02:00
2026-10-04 01:21:40 +02:00
2026-10-04 12:50:20 +02:00
2026-10-03 15:58:19 +02:00
2026-10-05 15:10:30 +02:00
2026-10-05 11:47:38 +02:00
2026-10-05 19:23:30 +02:00
2026-09-29 15:07:40 +02:00
2026-10-05 14:33:53 +02:00
2026-10-05 09:59:19 +02:00
2026-10-05 10:11:27 +02:00
2026-10-06 02:16:27 +02:00
2026-10-03 15:58:19 +02:00
2026-10-05 15:10:30 +02:00
2026-10-05 11:50:52 +02:00
2026-09-30 21:10:18 +02:00
2026-10-05 23:39:13 +02:00
2026-10-05 18:34:37 +02:00
2026-10-04 13:02:23 +02:00
2026-10-06 02:16:27 +02:00
2026-10-06 02:13:42 +02:00
2026-10-04 13:02:23 +02:00
2026-10-04 13:15:39 +02:00
2026-10-05 12:01:25 +02:00
2026-10-05 10:11:27 +02:00
2026-10-04 13:02:23 +02:00
2026-10-04 13:02:23 +02:00
2026-10-05 15:10:30 +02:00
2026-10-06 02:16:27 +02:00
2026-10-03 15:58:19 +02:00
2026-10-04 13:15:39 +02:00
2026-10-03 23:33:51 +02:00
2026-09-30 21:10:18 +02:00
2026-10-03 23:33:51 +02:00
2026-10-05 23:43:14 +02:00
2026-10-05 15:10:30 +02:00
2026-10-05 10:11:27 +02:00
2026-10-03 23:33:51 +02:00
2026-10-06 02:16:27 +02:00
2026-10-04 02:34:06 +02:00
2026-10-03 15:58:19 +02:00
2026-10-06 02:16:27 +02:00
2026-10-04 12:50:20 +02:00
2026-10-04 16:34:02 +02:00
2026-10-06 02:13:42 +02:00
2026-09-30 21:10:18 +02:00
2026-10-04 12:50:20 +02:00
2026-10-04 12:50:20 +02:00
2026-10-06 02:16:27 +02:00
2026-09-30 22:29:28 +02:00
2026-09-30 20:49:21 +02:00
2026-10-04 15:42:56 +02:00
2026-10-04 01:17:41 +02:00
2026-10-06 02:16:27 +02:00
2026-10-06 09:35:55 +02:00
2026-10-06 09:35:55 +02:00
2026-10-06 02:16:27 +02:00
2026-09-30 22:29:28 +02:00
2026-10-06 02:16:27 +02:00
2026-10-06 02:16:27 +02:00
2026-10-06 02:16:27 +02:00
2026-10-01 02:02:30 +02:00
2026-10-06 01:29:20 +02:00
2026-10-04 00:34:31 +02:00
2026-10-06 00:03:40 +02:00
2026-10-05 11:47:59 +02:00
2026-10-05 15:10:30 +02:00
2026-10-03 12:59:07 +02:00
2026-10-05 15:10:30 +02:00
2026-10-04 03:59:50 +02:00
2026-10-03 23:33:51 +02:00
2026-09-29 11:51:39 +02:00
2026-09-30 20:49:21 +02:00
2026-10-04 00:52:31 +02:00
2026-10-05 15:10:30 +02:00
2026-10-04 12:50:20 +02:00
2026-10-04 12:25:28 +02:00
2026-10-04 12:25:28 +02:00
2026-10-04 13:15:39 +02:00
2026-10-05 15:10:30 +02:00
2026-10-06 02:16:27 +02:00
2026-10-05 10:03:30 +02:00
2026-10-04 04:04:10 +02:00
2026-09-25 18:08:28 +02:00
2026-10-05 17:42:08 +02:00
2026-10-06 02:16:27 +02:00
2026-10-05 14:05:52 +02:00
2026-10-05 10:11:27 +02:00
2026-10-06 02:16:27 +02:00
2026-10-06 02:16:27 +02:00
2026-10-04 17:07:40 +02:00
2026-10-03 15:58:19 +02:00
2026-09-30 22:29:28 +02:00
2026-10-05 15:10:30 +02:00
2026-10-04 13:02:23 +02:00
2026-10-04 12:38:40 +02:00
2026-09-29 11:51:39 +02:00
2026-10-03 10:54:43 +02:00
2026-10-04 12:50:20 +02:00
2026-10-06 11:48:57 +02:00
2026-10-05 18:09:42 +02:00
2026-10-06 00:03:40 +02:00
2026-10-04 12:50:20 +02:00
2026-10-04 16:50:57 +02:00
2026-10-05 00:34:40 +02:00
2026-10-03 15:58:19 +02:00
2026-09-30 21:01:47 +02:00
2026-10-04 13:02:23 +02:00
2026-10-05 15:10:30 +02:00
2026-10-04 13:21:47 +02:00
2026-10-04 13:21:47 +02:00
2026-10-04 11:34:36 +02:00
2026-10-04 04:04:35 +02:00
2026-10-04 04:04:35 +02:00