Packages

Opinionated and batteries-included authentication for Phoenix applications.

Current section

Files

Jump to
ez_auth priv repo migrations 20260517133508_ez_auth_create_users.exs
Raw

priv/repo/migrations/20260517133508_ez_auth_create_users.exs

# This file was generated by `mix ez_auth.install`.
# Regenerate it by rerunning the installer after updating EzAuth.
defmodule EzAuth.TestRepo.Migrations.EzAuthCreateUsers do
use Ecto.Migration
def change do
create table(:users, prefix: "auth") do
add :name, :string
add :username, :citext
add :hashed_password, :string
add :metadata, :map, null: false, default: %{}
add :anonymous, :boolean, null: false, default: false
timestamps(type: :utc_datetime)
end
create unique_index(:users, [:username], prefix: "auth")
end
end