feat: replace php migration with django migration
- keep latest legacy version in initial migration file - move propel schema to api legacy app - remove legacy upgrade tool
This commit is contained in:
parent
ee98387264
commit
0e4bc4cacd
85 changed files with 1005 additions and 1000 deletions
33
api/libretime_api/legacy/migrations/0007_2_5_9.py
Normal file
33
api/libretime_api/legacy/migrations/0007_2_5_9.py
Normal file
|
@ -0,0 +1,33 @@
|
|||
from django.db import migrations
|
||||
|
||||
from ._migrations import legacy_migration_factory
|
||||
|
||||
UP = """
|
||||
CREATE TABLE cloud_file
|
||||
(
|
||||
id serial NOT NULL,
|
||||
resource_id text NOT NULL,
|
||||
storage_backend text NOT NULL,
|
||||
cc_file_id integer NOT NULL,
|
||||
CONSTRAINT cloud_file_pkey PRIMARY KEY (id),
|
||||
CONSTRAINT "cloud_file_FK_1" FOREIGN KEY (cc_file_id)
|
||||
REFERENCES cc_files (id) MATCH SIMPLE
|
||||
ON UPDATE NO ACTION ON DELETE CASCADE
|
||||
)
|
||||
"""
|
||||
|
||||
DOWN = None
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
dependencies = [
|
||||
("legacy", "0006_2_5_5"),
|
||||
]
|
||||
operations = [
|
||||
migrations.RunPython(
|
||||
code=legacy_migration_factory(
|
||||
target="2.5.9",
|
||||
sql=UP,
|
||||
)
|
||||
)
|
||||
]
|
Loading…
Add table
Add a link
Reference in a new issue