aboutsummaryrefslogtreecommitdiff
path: root/db/migrate
diff options
context:
space:
mode:
authorChristopher Baines <mail@cbaines.net>2018-05-30 20:17:02 +0100
committerChristopher Baines <mail@cbaines.net>2018-05-30 20:17:50 +0100
commit8b1ae33144bc4d496980ffc16cd304c8f107aff4 (patch)
tree198b02c2d5f649b319742f22c80cfa482f1e3d45 /db/migrate
parent31013afdfb53d849f8dabb86f92b467b1f016818 (diff)
downloadgovuk-mini-environment-admin-8b1ae33144bc4d496980ffc16cd304c8f107aff4.tar
govuk-mini-environment-admin-8b1ae33144bc4d496980ffc16cd304c8f107aff4.tar.gz
Add a new DataSnapshot model to store data snapshots
Diffstat (limited to 'db/migrate')
-rw-r--r--db/migrate/20180530191341_create_govuk_guix_data_snapshots.rb13
1 files changed, 13 insertions, 0 deletions
diff --git a/db/migrate/20180530191341_create_govuk_guix_data_snapshots.rb b/db/migrate/20180530191341_create_govuk_guix_data_snapshots.rb
new file mode 100644
index 0000000..3327127
--- /dev/null
+++ b/db/migrate/20180530191341_create_govuk_guix_data_snapshots.rb
@@ -0,0 +1,13 @@
+class CreateGovukGuixDataSnapshots < ActiveRecord::Migration[5.1]
+ def change
+ create_table :govuk_guix_data_snapshots do |t|
+ t.string :store_path, null: false
+ t.boolean :archived, default: false, null: false
+ t.json :manifest, null: false
+
+ t.timestamps
+ end
+
+ add_index :govuk_guix_data_snapshots, :store_path, unique: true
+ end
+end