1
0
mirror of https://github.com/dkmstr/openuds.git synced 2024-12-25 23:21:41 +03:00

Added squashed migration from 26 to 38

This commit is contained in:
Adolfo Gómez García 2021-04-22 17:56:50 +02:00
parent 7502fe3bcc
commit 6e438bf4cb

View File

@ -0,0 +1,252 @@
# Generated by Django 3.2 on 2021-04-22 17:55
import datetime
from django.db import migrations, models
import django.db.models.deletion
# Functions from the following migrations need manual copying.
# Move them and any dependencies into this file, then update the
# RunPython operations to refer to the local versions:
# uds.migrations.0038_auto_20200505_config
class Migration(migrations.Migration):
replaces = [('uds', '0026_auto_20180302_0525'), ('uds', '0027_deployedservice_allow_users_reset'), ('uds', '0028_auto_20180316_1001'), ('uds', '0029_auto_20181003_1049'), ('uds', '0030_auto_20190814_0912'), ('uds', '0031_auto_20190814_0943'), ('uds', '0032_auto_20190814_0945'), ('uds', '0033_auto_20190814_0951'), ('uds', '0034_actortoken'), ('uds', '0035_authenticator_visible'), ('uds', '0036_auto_20200131_1224'), ('uds', '0037_service_token'), ('uds', '0038_auto_20200505_config')]
dependencies = [
('uds', '0001_squashed_0025_deployedservice_ignores_unused'),
]
operations = [
migrations.AlterField(
model_name='dbfile',
name='created',
field=models.DateTimeField(),
),
migrations.AlterField(
model_name='dbfile',
name='modified',
field=models.DateTimeField(),
),
migrations.AlterField(
model_name='delayedtask',
name='insert_date',
field=models.DateTimeField(),
),
migrations.AlterField(
model_name='scheduler',
name='last_execution',
field=models.DateTimeField(db_index=True),
),
migrations.AlterField(
model_name='userservice',
name='state_date',
field=models.DateTimeField(db_index=True),
),
migrations.AddField(
model_name='deployedservice',
name='allow_users_reset',
field=models.BooleanField(default=False),
),
migrations.CreateModel(
name='Account',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('uuid', models.CharField(default=None, max_length=50, null=True, unique=True)),
('name', models.CharField(db_index=True, max_length=128)),
('time_mark', models.DateTimeField(default=datetime.datetime(1972, 7, 1, 0, 0))),
('comments', models.CharField(max_length=256)),
('tags', models.ManyToManyField(to='uds.Tag')),
],
options={
'db_table': 'uds_accounts',
},
),
migrations.CreateModel(
name='AccountUsage',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('uuid', models.CharField(default=None, max_length=50, null=True, unique=True)),
('user_name', models.CharField(db_index=True, default='', max_length=128)),
('user_uuid', models.CharField(db_index=True, default='', max_length=50)),
('pool_name', models.CharField(db_index=True, default='', max_length=128)),
('pool_uuid', models.CharField(db_index=True, default='', max_length=50)),
('start', models.DateTimeField(default=datetime.datetime(1972, 7, 1, 0, 0))),
('end', models.DateTimeField(default=datetime.datetime(1972, 7, 1, 0, 0))),
('account', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='usages', to='uds.account')),
('user_service', models.OneToOneField(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='accounting', to='uds.userservice')),
],
options={
'db_table': 'uds_acc_usage',
},
),
migrations.CreateModel(
name='Proxy',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('uuid', models.CharField(default=None, max_length=50, null=True, unique=True)),
('name', models.CharField(db_index=True, max_length=128)),
('comments', models.CharField(max_length=256)),
('host', models.CharField(max_length=256)),
('port', models.PositiveIntegerField(default=9090)),
('ssl', models.BooleanField(default=True)),
('check_cert', models.BooleanField(default=False)),
('tags', models.ManyToManyField(to='uds.Tag')),
],
options={
'db_table': 'uds_proxies',
},
),
migrations.RemoveField(
model_name='deployedservice',
name='meta_pools',
),
migrations.AddField(
model_name='deployedservice',
name='visible',
field=models.BooleanField(default=True),
),
migrations.AddField(
model_name='ticketstore',
name='owner',
field=models.CharField(blank=True, default=None, max_length=8, null=True),
),
migrations.AddField(
model_name='deployedservice',
name='account',
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='servicesPools', to='uds.account'),
),
migrations.AddField(
model_name='service',
name='proxy',
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='services', to='uds.proxy'),
),
migrations.CreateModel(
name='CalendarAccessMeta',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('uuid', models.CharField(default=None, max_length=50, null=True, unique=True)),
('access', models.CharField(default='DENY', max_length=8)),
('priority', models.IntegerField(db_index=True, default=0)),
('calendar', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='uds.calendar')),
],
options={
'db_table': 'uds_cal_maccess',
'ordering': ('priority',),
},
),
migrations.CreateModel(
name='MetaPool',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('uuid', models.CharField(default=None, max_length=50, null=True, unique=True)),
('name', models.CharField(default='', max_length=128)),
('short_name', models.CharField(default='', max_length=32)),
('comments', models.CharField(default='', max_length=256)),
('visible', models.BooleanField(default=True)),
('fallbackAccess', models.CharField(default='ALLOW', max_length=8)),
('policy', models.SmallIntegerField(default=0)),
('accessCalendars', models.ManyToManyField(related_name='accessMeta', through='uds.CalendarAccessMeta', to='uds.Calendar')),
('assignedGroups', models.ManyToManyField(db_table='uds__meta_grps', related_name='metaPools', to='uds.Group')),
('image', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='metaPools', to='uds.image')),
],
options={
'db_table': 'uds__pool_meta',
'abstract': False,
},
),
migrations.CreateModel(
name='MetaPoolMember',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('uuid', models.CharField(default=None, max_length=50, null=True, unique=True)),
('priority', models.PositiveIntegerField(default=0)),
('enabled', models.BooleanField(default=True)),
('meta_pool', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='members', to='uds.metapool')),
('pool', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='memberOfMeta', to='uds.deployedservice')),
],
options={
'db_table': 'uds__meta_pool_member',
'abstract': False,
},
),
migrations.AlterField(
model_name='calendaraccess',
name='service_pool',
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='calendarAccess', to='uds.deployedservice'),
),
migrations.AddField(
model_name='metapool',
name='pools',
field=models.ManyToManyField(related_name='meta', through='uds.MetaPoolMember', to='uds.DeployedService'),
),
migrations.AddField(
model_name='metapool',
name='servicesPoolGroup',
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='metaPools', to='uds.servicespoolgroup'),
),
migrations.AddField(
model_name='metapool',
name='tags',
field=models.ManyToManyField(to='uds.Tag'),
),
migrations.AddField(
model_name='calendaraccessmeta',
name='meta_pool',
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='calendarAccess', to='uds.metapool'),
),
migrations.RenameModel(
old_name='DeployedService',
new_name='ServicePool',
),
migrations.RenameModel(
old_name='DeployedServicePublication',
new_name='ServicePoolPublication',
),
migrations.RenameModel(
old_name='DeployedServicePublicationChangelog',
new_name='ServicePoolPublicationChangelog',
),
migrations.RenameModel(
old_name='ServicesPoolGroup',
new_name='ServicePoolGroup',
),
migrations.CreateModel(
name='ActorToken',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('username', models.CharField(max_length=128)),
('ip_from', models.CharField(max_length=128)),
('ip', models.CharField(max_length=128)),
('hostname', models.CharField(max_length=128)),
('mac', models.CharField(db_index=True, max_length=128, unique=True)),
('pre_command', models.CharField(blank=True, default='', max_length=255)),
('post_command', models.CharField(blank=True, default='', max_length=255)),
('runonce_command', models.CharField(blank=True, default='', max_length=255)),
('log_level', models.IntegerField()),
('token', models.CharField(db_index=True, max_length=48, unique=True)),
('stamp', models.DateTimeField()),
],
),
migrations.AddField(
model_name='authenticator',
name='visible',
field=models.BooleanField(default=True),
),
migrations.AddField(
model_name='metapool',
name='calendar_message',
field=models.CharField(default='', max_length=256),
),
migrations.AddField(
model_name='servicepool',
name='calendar_message',
field=models.CharField(default='', max_length=256),
),
migrations.AddField(
model_name='service',
name='token',
field=models.CharField(blank=True, default=None, max_length=32, null=True, unique=True),
),
]