1
0
Fork 0
mirror of https://github.com/retspen/webvirtcloud synced 2026-11-08 11:16:47 +00:00
webvirtcloud/instances/migrations
catborise f1f52aac42 refactor: the API's serializers and the new VM form no longer need models
Networks, Interfaces, Storages, Storage, Volume, MigrateInstance and
CreateInstance were unmanaged models with no table, there only so that
ModelSerializers and the new VM ModelForm could take their fields. They
made content types and migrations, and their DO_NOTHING foreign keys
added reverse accessors that meant nothing (Compute.host,
Compute.target_host, Instance.source_host).

The serializers are plain Serializers and NewVMForm a Form, field for
field as the models gave them (types, lengths, required, defaults, the
minimum of 1 for vCPUs, memory and disk size; the form's labels are
still derived from the field names). Compared field by field before and
after, the API schema changes only where the models were wrong:
- no int64 bounds on the listing fields;
- the interface fields lose the titles that named the wrong column
  (type was "Status", state "Device", mac "Forward");
- a pool's volumes is a list of objects (it was described as an
  integer) and a volume's allocation an integer (it was untyped).
One migration per app deletes the models; none touches a table.
2026-11-06 13:46:27 +03:00
..
0001_initial.py lint with black python. convert f style strings to old one. some small fixes 2020-11-05 12:34:31 +03:00
0002_permissionset.py Added 'instances:clone_instances' permission 2020-05-28 11:20:23 +06:00
0003_auto_20200615_0637.py Added missing migrations 2020-06-15 12:38:44 +06:00
0004_auto_20200618_0817.py Instances overhaul 2020-07-13 15:33:09 +06:00
0005_flavor.py Instances overhaul 2020-07-13 15:33:09 +06:00
0006_addFlavors.py lint with black python. convert f style strings to old one. some small fixes 2020-11-05 12:34:31 +03:00
0007_auto_20200624_0821.py Instances overhaul 2020-07-13 15:33:09 +06:00
0008_auto_20200708_0950.py Instances overhaul 2020-07-13 15:33:09 +06:00
0009_auto_20200717_0524.py make console password optional for users with permissions 2020-07-17 11:05:47 +03:00
0010_auto_20220722_0812.py Rest framework (#24) 2022-08-22 15:12:33 +03:00
0011_createinstance_migrateinstance.py add missing migrations for new models 2022-08-24 09:34:16 +03:00
0012_instance_unique_compute_uuid.py fix(reconciliation): serialize compute sync and enforce UUID identity 2026-09-28 14:55:49 +03:00
0013_instancetombstone.py fix(computes): VM ownership survives a move or a short absence 2026-10-04 01:08:11 +03:00
0014_instancetombstone_host.py fix(admin): Removed VMs shows the host a VM left and confirms a delete 2026-10-26 11:48:40 +03:00
0015_remove_api_only_models.py refactor: the API's serializers and the new VM form no longer need models 2026-11-06 13:46:27 +03:00
__init__.py Initial commit 2015-02-27 10:53:51 +02:00