restart config id after truncate

This commit is contained in:
Alexander Strizhakov 2020-01-23 17:48:45 +03:00
parent 4344c5d5b9
commit e8e57e398f
No known key found for this signature in database
GPG Key ID: 022896A53AEF1381

View File

@ -53,6 +53,7 @@ defmodule Mix.Tasks.Pleroma.Config do
defp do_migrate_to_db(config_file) do
if File.exists?(config_file) do
Ecto.Adapters.SQL.query!(Repo, "TRUNCATE config;")
Ecto.Adapters.SQL.query!(Repo, "ALTER SEQUENCE config_id_seq RESTART;")
custom_config =
config_file