uncloud/opennebula/migrations/0001_initial.py

34 lines
1.5 KiB
Python
Raw Normal View History

# Generated by Django 3.0.6 on 2020-08-01 16:38
2020-02-23 10:41:51 +00:00
from django.conf import settings
import django.contrib.postgres.fields.jsonb
from django.db import migrations, models
2020-02-23 10:41:51 +00:00
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
2020-02-23 10:41:51 +00:00
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
('uncloud_pay', '0001_initial'),
]
operations = [
migrations.CreateModel(
name='VM',
fields=[
('extra_data', django.contrib.postgres.fields.jsonb.JSONField(blank=True, editable=False, null=True)),
('status', models.CharField(choices=[('PENDING', 'Pending'), ('AWAITING_PAYMENT', 'Awaiting payment'), ('BEING_CREATED', 'Being created'), ('SCHEDULED', 'Scheduled'), ('ACTIVE', 'Active'), ('MODIFYING', 'Modifying'), ('DELETED', 'Deleted'), ('DISABLED', 'Disabled'), ('UNUSABLE', 'Unusable')], default='AWAITING_PAYMENT', max_length=32)),
2020-02-23 10:41:51 +00:00
('vmid', models.IntegerField(primary_key=True, serialize=False)),
('data', django.contrib.postgres.fields.jsonb.JSONField()),
('order', models.ForeignKey(editable=False, null=True, on_delete=django.db.models.deletion.CASCADE, to='uncloud_pay.Order')),
('owner', models.ForeignKey(editable=False, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
],
options={
'abstract': False,
},
),
]