aboutsummaryrefslogtreecommitdiff
path: root/db/migrate/20201005154908_create_agents.rb
diff options
context:
space:
mode:
authorhellekin <hellekin@cepheide.org>2020-10-06 00:21:40 +0200
committerhellekin <hellekin@cepheide.org>2020-10-06 00:21:40 +0200
commitaff9cad1d32eaf534fdd2a53d5cf3616404ff75a (patch)
tree2b8878678657713a2e99645a52e2eed751969161 /db/migrate/20201005154908_create_agents.rb
parent0b6a7bafaef612793fa9cdf0646cbb47ffe0e583 (diff)
downloadincommon-map-aff9cad1d32eaf534fdd2a53d5cf3616404ff75a.tar.gz
Ensure only one Agent exists for a given group
Diffstat (limited to 'db/migrate/20201005154908_create_agents.rb')
-rw-r--r--db/migrate/20201005154908_create_agents.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/db/migrate/20201005154908_create_agents.rb b/db/migrate/20201005154908_create_agents.rb
index 32792ee..cc5a00f 100644
--- a/db/migrate/20201005154908_create_agents.rb
+++ b/db/migrate/20201005154908_create_agents.rb
@@ -6,6 +6,7 @@ class CreateAgents < ActiveRecord::Migration[6.0]
t.timestamps
end
+ add_index :agents, [:name], unique: true
add_index :agents, [:uuid], unique: true
end
end