feat(server): host schema, context, auth, status transitions

This commit is contained in:
Carsten 2026-04-21 22:02:24 +02:00
parent bab31b7c4e
commit b141ee7816
5 changed files with 174 additions and 0 deletions

View file

@ -0,0 +1,19 @@
defmodule Server.Repo.Migrations.CreateHosts do
use Ecto.Migration
def change do
create table(:hosts) do
add :name, :string, null: false
add :token_hash, :string, null: false
add :agent_version, :string
add :proxmox_version, :string
add :zfs_version, :string
add :status, :string, null: false, default: "never_connected"
add :last_seen_at, :utc_datetime_usec
timestamps(type: :utc_datetime_usec)
end
create unique_index(:hosts, [:name])
end
end