From 1c2d5cf605ea6391d913e79c46acdf55809986f6 Mon Sep 17 00:00:00 2001 From: j3s Date: Tue, 19 Jan 2021 19:24:07 -0600 Subject: [PATCH] Add Alpine 3.13 --- capsulflask/db.py | 2 +- capsulflask/schema_migrations/11_down_alpine_3.13.sql | 5 +++++ capsulflask/schema_migrations/11_up_alpine_3.13.sql | 6 ++++++ 3 files changed, 12 insertions(+), 1 deletion(-) create mode 100644 capsulflask/schema_migrations/11_down_alpine_3.13.sql create mode 100644 capsulflask/schema_migrations/11_up_alpine_3.13.sql diff --git a/capsulflask/db.py b/capsulflask/db.py index 11d60cb..4bf1152 100644 --- a/capsulflask/db.py +++ b/capsulflask/db.py @@ -40,7 +40,7 @@ def init_app(app): hasSchemaVersionTable = False actionWasTaken = False schemaVersion = 0 - desiredSchemaVersion = 10 + desiredSchemaVersion = 11 cursor = connection.cursor() diff --git a/capsulflask/schema_migrations/11_down_alpine_3.13.sql b/capsulflask/schema_migrations/11_down_alpine_3.13.sql new file mode 100644 index 0000000..5b4a883 --- /dev/null +++ b/capsulflask/schema_migrations/11_down_alpine_3.13.sql @@ -0,0 +1,5 @@ +DELETE FROM os_images WHERE id = 'alpine313'; + +UPDATE os_images SET deprecated = FALSE WHERE id = 'alpine312'; + +UPDATE schemaversion SET version = 10; diff --git a/capsulflask/schema_migrations/11_up_alpine_3.13.sql b/capsulflask/schema_migrations/11_up_alpine_3.13.sql new file mode 100644 index 0000000..d46e63a --- /dev/null +++ b/capsulflask/schema_migrations/11_up_alpine_3.13.sql @@ -0,0 +1,6 @@ +INSERT INTO os_images (id, template_image_file_name, description, deprecated) +VALUES ('alpine313', 'alpine/3.13/root.img.qcow2', 'Alpine Linux 3.13', FALSE); + +UPDATE os_images SET deprecated = TRUE WHERE id = 'alpine312'; + +UPDATE schemaversion SET version = 11;