Commit 50740229 authored by Lukas Burgey's avatar Lukas Burgey

Start over with the migrations

With all those strange changes, the migrations were broken. I removed
all of them and started with new migrations.

For django-polymorphic i had to rename the Model 'bases' in the auto
generated migrations, as the seem to be case sensitive.
parent 8193af5b
This diff is collapsed.
# Generated by Django 2.1 on 2018-08-06 09:41
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('backend', '0001_initial'),
]
operations = [
migrations.AlterField(
model_name='user',
name='user_type',
field=models.CharField(choices=[('apiclient', 'API-Client'), ('oidcuser', 'OIDC User'), ('admin', 'Admin')], max_length=20),
),
]
# Generated by Django 2.1 on 2018-08-09 12:09
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('backend', '0002_auto_20180806_0941'),
]
operations = [
migrations.AlterField(
model_name='user',
name='user_type',
field=models.CharField(choices=[('apiclient', 'API-Client'), ('oidcuser', 'OIDC User'), ('admin', 'Admin')], default='apiclient', max_length=20),
),
]
# Generated by Django 2.1 on 2018-08-09 14:55
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('auth', '0009_alter_user_last_name_max_length'),
('backend', '0003_auto_20180809_1209'),
]
operations = [
migrations.CreateModel(
name='NewDeployment',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('state_target', models.CharField(choices=[('deployment_pending', 'Deployment Pending'), ('removal_pending', 'Removal Pending'), ('deployed', 'Deployed'), ('not_deployed', 'Not Deployed'), ('questionnaire', 'Questionnaire'), ('failed', 'Failed'), ('rejected', 'Rejected')], default='deployed', max_length=50)),
('is_active', models.BooleanField(default=True)),
('group', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='deployments', to='auth.Group')),
('service', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='deployments', to='backend.Service')),
('user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='deployments', to=settings.AUTH_USER_MODEL)),
],
),
migrations.RemoveField(
model_name='deployment',
name='group',
),
migrations.RemoveField(
model_name='deployment',
name='service',
),
migrations.RemoveField(
model_name='deployment',
name='ssh_keys',
),
migrations.RemoveField(
model_name='deployment',
name='user',
),
migrations.RemoveField(
model_name='deploymentstate',
name='deployment',
),
migrations.RemoveField(
model_name='deploymentstate',
name='key',
),
migrations.AlterField(
model_name='deploymentstateitem',
name='parent',
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='state_items', to='backend.NewDeployment'),
),
migrations.AlterField(
model_name='rabbitmqinstance',
name='vhost',
field=models.CharField(default='/', max_length=150),
),
migrations.DeleteModel(
name='Deployment',
),
migrations.DeleteModel(
name='DeploymentState',
),
]
# Generated by Django 2.1 on 2018-08-09 14:59
from django.db import migrations, models
import django.db.models.deletion
import django_mysql.models
import feudal.backend.models
class Migration(migrations.Migration):
dependencies = [
('backend', '0004_auto_20180809_1655'),
]
operations = [
migrations.CreateModel(
name='NewDeploymentStateItem',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('state', models.CharField(choices=[('deployment_pending', 'Deployment Pending'), ('removal_pending', 'Removal Pending'), ('deployed', 'Deployed'), ('not_deployed', 'Not Deployed'), ('questionnaire', 'Questionnaire'), ('failed', 'Failed'), ('rejected', 'Rejected')], default='deployment_pending', max_length=50)),
('message', models.TextField(default='', max_length=300)),
('questionnaire', django_mysql.models.JSONField(blank=True, default=feudal.backend.models.questionnaire_default, null=True)),
('credentials', django_mysql.models.JSONField(blank=True, default=feudal.backend.models.credential_default, null=True)),
('parent', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='state_items', to='backend.NewDeployment')),
('service', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='state_items', to='backend.Service')),
('site', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='state_items', to='backend.Site')),
],
),
migrations.RemoveField(
model_name='deploymentstateitem',
name='parent',
),
migrations.RemoveField(
model_name='deploymentstateitem',
name='service',
),
migrations.RemoveField(
model_name='deploymentstateitem',
name='site',
),
migrations.DeleteModel(
name='DeploymentStateItem',
),
]
# Generated by Django 2.1 on 2018-08-13 12:17
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('backend', '0005_auto_20180809_1659'),
]
operations = [
migrations.AlterField(
model_name='newdeployment',
name='state_target',
field=models.CharField(choices=[('deployment_pending', 'Deployment Pending'), ('removal_pending', 'Removal Pending'), ('deployed', 'Deployed'), ('not_deployed', 'Not Deployed'), ('questionnaire', 'Questionnaire'), ('failed', 'Failed'), ('rejected', 'Rejected')], default='not_deployed', max_length=50),
),
migrations.AlterField(
model_name='newdeploymentstateitem',
name='state',
field=models.CharField(choices=[('deployment_pending', 'Deployment Pending'), ('removal_pending', 'Removal Pending'), ('deployed', 'Deployed'), ('not_deployed', 'Not Deployed'), ('questionnaire', 'Questionnaire'), ('failed', 'Failed'), ('rejected', 'Rejected')], default='not_deployed', max_length=50),
),
]
# Generated by Django 2.1 on 2018-08-21 09:35
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('auth', '0009_alter_user_last_name_max_length'),
('backend', '0006_auto_20180813_1417'),
]
operations = [
migrations.CreateModel(
name='GroupDescription',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('description', models.TextField(max_length=1000)),
('Group', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='description', to='auth.Group')),
],
),
]
# Generated by Django 2.1 on 2018-08-21 09:40
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('backend', '0007_groupdescription'),
]
operations = [
migrations.RenameField(
model_name='groupdescription',
old_name='Group',
new_name='group',
),
]
# Generated by Django 2.1 on 2018-08-21 13:29
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('backend', '0008_auto_20180821_1140'),
]
operations = [
migrations.AlterField(
model_name='groupdescription',
name='group',
field=models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, related_name='description', to='auth.Group'),
),
]
# Generated by Django 2.1 on 2018-10-29 14:20
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('backend', '0009_auto_20180821_1529'),
]
operations = [
migrations.CreateModel(
name='CredentialState',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('state', models.CharField(choices=[('deployed', 'Deployed'), ('not_deployed', 'Not deployed')], default='not_deployed', max_length=50)),
('credential', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='credential_states', to='backend.SSHPublicKey')),
('target', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='credential_states', to='backend.NewDeploymentStateItem')),
],
),
]
# Generated by Django 2.1 on 2018-10-29 15:16
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('backend', '0010_credentialstate'),
]
operations = [
migrations.AlterField(
model_name='credentialstate',
name='state',
field=models.CharField(choices=[('deployment_pending', 'Deployment Pending'), ('removal_pending', 'Removal Pending'), ('deployed', 'Deployed'), ('not_deployed', 'Not Deployed'), ('questionnaire', 'Questionnaire'), ('failed', 'Failed'), ('rejected', 'Rejected')], default='not_deployed', max_length=50),
),
]
# Generated by Django 2.1.3 on 2018-11-07 10:53
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('backend', '0011_auto_20181029_1616'),
]
operations = [
migrations.AlterField(
model_name='credentialstate',
name='credential',
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='credential_states', to='backend.SSHPublicKey'),
),
]
# Generated by Django 2.1.3 on 2018-11-07 10:55
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('backend', '0012_auto_20181107_1153'),
]
operations = [
migrations.AddField(
model_name='credentialstate',
name='state_target',
field=models.CharField(choices=[('deployed', 'Deployed'), ('not_deployed', 'Not Deployed')], default='not_deployed', max_length=50),
),
]
# Generated by Django 2.1.3 on 2018-11-07 11:00
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('backend', '0013_credentialstate_state_target'),
]
operations = [
migrations.RemoveField(
model_name='credentialstate',
name='state_target',
),
]
# Generated by Django 2.1.3 on 2018-11-07 11:02
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('backend', '0014_remove_credentialstate_state_target'),
]
operations = [
migrations.AddField(
model_name='credentialstate',
name='state_target',
field=models.CharField(choices=[('deployed', 'Deployed'), ('not_deployed', 'Not Deployed')], default='not_deployed', max_length=50),
),
]
# Generated by Django 2.1.3 on 2018-11-07 16:33
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('backend', '0015_credentialstate_state_target'),
]
operations = [
migrations.AddField(
model_name='credentialstate',
name='_credential_deleted',
field=models.BooleanField(default=False),
),
]
# Generated by Django 2.1.3 on 2018-11-12 12:36
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('backend', '0016_credentialstate__credential_deleted'),
]
operations = [
migrations.AlterField(
model_name='newdeployment',
name='state_target',
field=models.CharField(choices=[('deployed', 'Deployed'), ('not_deployed', 'Not Deployed')], default='not_deployed', max_length=50),
),
]
# Generated by Django 2.1.3 on 2018-11-12 14:10
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('backend', '0018_auto_20181112_1336'),
]
operations = [
migrations.RemoveField(
model_name='newdeployment',
name='service',
),
]
# Generated by Django 2.1.3 on 2018-11-14 17:39
from django.db import migrations, models
import django.db.models.deletion
import django_mysql.models
import feudal.backend.auth.v1.models
class Migration(migrations.Migration):
dependencies = [
('contenttypes', '0002_remove_content_type_name'),
('backend', '0019_remove_newdeployment_service'),
]
operations = [
migrations.CreateModel(
name='EntitlementNameSpace',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.CharField(max_length=200, unique=True)),
],
),
migrations.CreateModel(
name='VO',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('name', models.CharField(max_length=200, unique=True)),
('description', models.TextField(blank=True, max_length=1000, null=True)),
],
options={
'base_manager_name': 'objects',
'abstract': False,
},
),
migrations.RemoveField(
model_name='groupdescription',
name='group',
),
migrations.RemoveField(
model_name='newdeployment',
name='group',
),
migrations.RemoveField(
model_name='service',
name='groups',
),
migrations.AddField(
model_name='oidcconfig',
name='ignore_subgroups',
field=models.BooleanField(default=False, help_text='Ignore subgroups of VO describing groups. E.g. ignores the group :foo:bar if :foo exists.'),
),
migrations.AddField(
model_name='oidcconfig',
name='userinfo_field_entitlements',
field=models.CharField(blank=True, default=None, help_text="The field in the userinfo (served by this IdP) that contains entitlements of the user. Leave blank if you don't want to use entitlements of this IdP", max_length=200, null=True),
),
migrations.AddField(
model_name='oidcconfig',
name='userinfo_field_groups',
field=models.CharField(blank=True, default=None, help_text="The field in the userinfo (served by this IdP) that contains groups of the user. Leave blank if you don't want to use groups of this IdP", max_length=200, null=True),
),
migrations.AddField(
model_name='oidcconfig',
name='vo_subtree_path',
field=models.CharField(blank=True, help_text='If not emtpy: Operate with groups of the described subtree of group (or entitlements). For example: Let\'s say the groups [/,/foo,/bar] exist and you set vo_subtree_path to "/". In that case the VO-Groups would be /foo and /bar', max_length=200, null=True),
),
migrations.AlterField(
model_name='oidcconfig',
name='scopes',
field=django_mysql.models.JSONField(default=feudal.backend.auth.v1.models.scopes_default, help_text='The scopes we request when requesting user infos'),
),
migrations.CreateModel(
name='Entitlement',
fields=[
('vo_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='backend.VO')),
('group_authority', models.CharField(max_length=200)),
('role', models.CharField(max_length=200)),
('name_space', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='entitlements', to='backend.EntitlementNameSpace')),
],
options={
'base_manager_name': 'objects',
'abstract': False,
},
bases=('backend.vo',),
),
migrations.CreateModel(
name='Group',
fields=[
('vo_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='backend.VO')),
],
options={
'base_manager_name': 'objects',
'abstract': False,
},
bases=('backend.vo',),
),
migrations.DeleteModel(
name='GroupDescription',
),
migrations.AddField(
model_name='vo',
name='idp',
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='vos', to='backend.OIDCConfig'),
),
migrations.AddField(
model_name='vo',
name='polymorphic_ctype',
field=models.ForeignKey(editable=False, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='polymorphic_backend.vo_set+', to='contenttypes.ContentType'),
),
migrations.AddField(
model_name='newdeployment',
name='vo',
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='deployments', to='backend.VO'),
),
migrations.AddField(
model_name='service',
name='vos',
field=models.ManyToManyField(blank=True, related_name='services', to='backend.VO'),
),
migrations.AddField(
model_name='user',
name='vos',
field=models.ManyToManyField(blank=True, to='backend.VO'),
),
migrations.AddField(
model_name='group',
name='parent',
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='group_childs', to='backend.VO'),
),
migrations.AddField(
model_name='entitlement',
name='parent',
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='entitlement_childs', to='backend.VO'),
),
]
# Generated by Django 2.1.3 on 2018-11-15 10:53
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('backend', '0020_auto_20181114_1839'),
]
operations = [
migrations.RemoveField(
model_name='entitlement',
name='parent',
),
migrations.RemoveField(
model_name='group',
name='parent',
),
migrations.AddField(
model_name='entitlement',
name='full_name',
field=models.CharField(default='', max_length=200),
preserve_default=False,
),
migrations.AlterField(
model_name='entitlement',
name='group_authority',
field=models.CharField(blank=True, max_length=200, null=True),
),
migrations.AlterField(
model_name='entitlement',
name='role',
field=models.CharField(blank=True, max_length=200, null=True),
),
]
# Generated by Django 2.1.3 on 2018-11-15 15:57
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('backend', '0021_auto_20181115_1153'),
]
operations = [
migrations.AddField(
model_name='newdeploymentstateitem',
name='user',
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='state_items', to=settings.AUTH_USER_MODEL),
),
]
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('backend', '0022_newdeploymentstateitem_user'),
]
operations = [
migrations.RenameModel('NewDeployment', 'Deployment'),
migrations.RenameModel('NewDeploymentStateItem', 'DeploymentState'),
]
# Generated by Django 2.1.3 on 2018-11-20 17:58
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('backend', '0023_rename'),
]
operations = [
migrations.AlterField(
model_name='deployment',
name='user',
field=models.ForeignKey(default=3, on_delete=django.db.models.deletion.CASCADE, related_name='deployments', to=settings.AUTH_USER_MODEL),
preserve_default=False,
),
migrations.AlterField(
model_name='deployment',
name='vo',
field=models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, related_name='deployments', to='backend.VO'),
preserve_default=False,
),
migrations.AlterField(
model_name='deploymentstate',
name='parent',
field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='state_items', to='backend.Deployment'),
),
]
# Generated by Django 2.1.3 on 2018-11-21 10:49
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('backend', '0024_auto_20181120_1858'),
]
operations = [