diff --git a/capsulflask/db.py b/capsulflask/db.py index b0e9a0d..a75663f 100644 --- a/capsulflask/db.py +++ b/capsulflask/db.py @@ -42,7 +42,7 @@ def init_app(app): hasSchemaVersionTable = False actionWasTaken = False schemaVersion = 0 - desiredSchemaVersion = 12 + desiredSchemaVersion = 13 cursor = connection.cursor() diff --git a/capsulflask/schema_migrations/13_down_coreos.sql b/capsulflask/schema_migrations/13_down_coreos.sql new file mode 100644 index 0000000..7ae6ee7 --- /dev/null +++ b/capsulflask/schema_migrations/13_down_coreos.sql @@ -0,0 +1,3 @@ +DELETE FROM os_images WHERE id = 'coreos'; + +UPDATE schemaversion SET version = 12; diff --git a/capsulflask/schema_migrations/13_up_coreos.sql b/capsulflask/schema_migrations/13_up_coreos.sql new file mode 100644 index 0000000..5d8928c --- /dev/null +++ b/capsulflask/schema_migrations/13_up_coreos.sql @@ -0,0 +1,4 @@ +INSERT INTO os_images (id, template_image_file_name, description, deprecated) +VALUES ('coreos', 'coreos/stable/root.img.qcow2', 'Fedora CoreOS Stable', FALSE); + +UPDATE schemaversion SET version = 13;