debianize-mobilizon/priv/repo/migrations/20171207162439_create_accounts.exs
Thomas Citharel 92d2045735 end
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
2018-01-09 17:52:26 +01:00

23 lines
543 B
Elixir

defmodule Eventos.Repo.Migrations.CreateAccounts do
use Ecto.Migration
def change do
create table(:accounts) do
add :username, :string, null: false
add :domain, :string
add :display_name, :string, null: false
add :description, :text
add :private_key, :text
add :public_key, :text, null: false
add :suspended, :boolean, default: false, null: false
add :uri, :string
add :url, :string
timestamps()
end
create unique_index(:accounts, [:username, :domain])
end
end