mirror of
https://github.com/SebastianWendel/nixpkgs.git
synced 2024-10-01 01:20:17 +02:00
02b15d0f5b
* Most significant is probably the patching necessary to run plausible
with postgres without superuser privilege. This change includes:
* updating ecto_sql to 3.6 where `CREATE DATABASE` is only executed if
it doesn't exist[1].
* patching a migration to only modify the `users.email` column (to use
`citext` rather than creating the extension. `plausible-postgres`
takes care of that).
* Correctly declare dependencies in systemd.
* A few minor fixes.
[1] 051baf669e
17 lines
629 B
Diff
17 lines
629 B
Diff
diff --git a/priv/repo/migrations/20190430140411_use_citext_for_email.exs b/priv/repo/migrations/20190430140411_use_citext_for_email.exs
|
|
index ecb6f80..f3bf12f 100644
|
|
--- a/priv/repo/migrations/20190430140411_use_citext_for_email.exs
|
|
+++ b/priv/repo/migrations/20190430140411_use_citext_for_email.exs
|
|
@@ -2,10 +2,6 @@ defmodule Plausible.Repo.Migrations.UseCitextForEmail do
|
|
use Ecto.Migration
|
|
|
|
def change do
|
|
- execute "CREATE EXTENSION IF NOT EXISTS citext;"
|
|
-
|
|
- alter table(:users) do
|
|
- modify :email, :citext, null: false
|
|
- end
|
|
+ execute "ALTER TABLE users ALTER COLUMN email TYPE citext;"
|
|
end
|
|
end
|