small fix, don't worry about it

This commit is contained in:
Tomas Dvorak
2026-04-10 12:02:36 +02:00
parent 08bd0c6e5c
commit 08cb5754f3
638 changed files with 57332 additions and 34706 deletions
@@ -0,0 +1,7 @@
-- +goose Up
-- Baseline migration for goose-managed schema evolution.
SELECT 1;
-- +goose Down
-- Baseline down migration intentionally does not mutate schema.
SELECT 1;
@@ -0,0 +1,20 @@
-- +goose Up
CREATE TABLE IF NOT EXISTS agent_heartbeats (
id VARCHAR(255) PRIMARY KEY,
node_agent_id VARCHAR(255) NOT NULL REFERENCES node_agents(id) ON DELETE CASCADE,
timestamp TIMESTAMPTZ NOT NULL DEFAULT NOW(),
status VARCHAR(50) NOT NULL DEFAULT 'unknown',
resources JSONB NOT NULL DEFAULT '{}'::jsonb,
container_count INTEGER NOT NULL DEFAULT 0,
system_load JSONB NOT NULL DEFAULT '{}'::jsonb,
uptime BIGINT NOT NULL DEFAULT 0,
version VARCHAR(50) NOT NULL DEFAULT '',
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);
CREATE INDEX IF NOT EXISTS idx_agent_heartbeats_node_agent_id ON agent_heartbeats(node_agent_id);
CREATE INDEX IF NOT EXISTS idx_agent_heartbeats_timestamp ON agent_heartbeats(timestamp);
CREATE INDEX IF NOT EXISTS idx_agent_heartbeats_node_timestamp ON agent_heartbeats(node_agent_id, timestamp DESC);
-- +goose Down
DROP TABLE IF EXISTS agent_heartbeats;