From da7164317681aeca442ccef6ed0a74ad1952f0bf Mon Sep 17 00:00:00 2001 From: Ilion Beyst Date: Sun, 27 Feb 2022 21:47:17 +0100 Subject: seed simplebot on server startup --- planetwars-server/migrations/2021-12-18-130837_bots/up.sql | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'planetwars-server/migrations/2021-12-18-130837_bots') diff --git a/planetwars-server/migrations/2021-12-18-130837_bots/up.sql b/planetwars-server/migrations/2021-12-18-130837_bots/up.sql index a23fbf7..b158940 100644 --- a/planetwars-server/migrations/2021-12-18-130837_bots/up.sql +++ b/planetwars-server/migrations/2021-12-18-130837_bots/up.sql @@ -1,11 +1,9 @@ CREATE TABLE bots ( id serial PRIMARY KEY, owner_id integer REFERENCES users(id), - name text NOT NULL + name text UNIQUE NOT NULL ); -CREATE UNIQUE INDEX bots_index ON bots(owner_id, name); - CREATE TABLE code_bundles ( id serial PRIMARY KEY, bot_id integer REFERENCES bots(id), -- cgit v1.2.3