jumpserver/apps/terminal/migrations/0054_auto_20221027_1125.py

89 lines
4.9 KiB
Python
Raw Normal View History

2022-10-27 08:26:15 +00:00
# Generated by Django 3.2.14 on 2022-10-27 03:25
2022-10-22 03:17:02 +00:00
from django.db import migrations, models
import django.db.models.deletion
import uuid
class Migration(migrations.Migration):
dependencies = [
2022-10-27 08:26:15 +00:00
('assets', '0107_auto_20221019_1115'),
2022-10-22 03:17:02 +00:00
('terminal', '0053_auto_20220830_1244'),
]
operations = [
migrations.CreateModel(
name='Applet',
fields=[
('created_by', models.CharField(blank=True, max_length=32, null=True, verbose_name='Created by')),
('updated_by', models.CharField(blank=True, max_length=32, null=True, verbose_name='Updated by')),
('date_created', models.DateTimeField(auto_now_add=True, null=True, verbose_name='Date created')),
('date_updated', models.DateTimeField(auto_now=True, verbose_name='Date updated')),
('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False)),
('name', models.SlugField(max_length=128, unique=True, verbose_name='Name')),
2022-10-25 12:09:05 +00:00
('display_name', models.CharField(max_length=128, verbose_name='Display name')),
2022-10-22 03:17:02 +00:00
('version', models.CharField(max_length=16, verbose_name='Version')),
('author', models.CharField(max_length=128, verbose_name='Author')),
2022-10-25 04:57:34 +00:00
('type', models.CharField(choices=[('general', 'General'), ('web', 'Web')], default='general', max_length=16, verbose_name='Type')),
2022-10-27 08:26:15 +00:00
('is_active', models.BooleanField(default=True, verbose_name='Is active')),
2022-10-22 03:17:02 +00:00
('protocols', models.JSONField(default=list, verbose_name='Protocol')),
2022-10-25 04:57:34 +00:00
('tags', models.JSONField(default=list, verbose_name='Tags')),
2022-10-22 03:17:02 +00:00
('comment', models.TextField(blank=True, default='', verbose_name='Comment')),
],
options={
'abstract': False,
},
),
migrations.CreateModel(
2022-10-25 04:57:34 +00:00
name='AppletHost',
2022-10-22 03:17:02 +00:00
fields=[
2022-10-27 08:26:15 +00:00
('host_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='assets.host')),
2022-10-22 03:17:02 +00:00
('date_synced', models.DateTimeField(blank=True, null=True, verbose_name='Date synced')),
('status', models.CharField(max_length=16, verbose_name='Status')),
],
options={
'abstract': False,
},
2022-10-27 08:26:15 +00:00
bases=('assets.host',),
2022-10-22 03:17:02 +00:00
),
migrations.CreateModel(
2022-10-25 04:57:34 +00:00
name='AppletPublication',
2022-10-22 03:17:02 +00:00
fields=[
('created_by', models.CharField(blank=True, max_length=32, null=True, verbose_name='Created by')),
('updated_by', models.CharField(blank=True, max_length=32, null=True, verbose_name='Updated by')),
('date_created', models.DateTimeField(auto_now_add=True, null=True, verbose_name='Date created')),
('date_updated', models.DateTimeField(auto_now=True, verbose_name='Date updated')),
('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False)),
2022-11-01 09:04:44 +00:00
('status', models.CharField(default='', max_length=16, verbose_name='Status')),
2022-10-22 03:17:02 +00:00
('comment', models.TextField(blank=True, default='', verbose_name='Comment')),
2022-10-25 04:57:34 +00:00
('applet', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='terminal.applet', verbose_name='Applet')),
('host', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='terminal.applethost', verbose_name='Host')),
2022-10-22 03:17:02 +00:00
],
options={
2022-10-25 04:57:34 +00:00
'unique_together': {('applet', 'host')},
2022-10-22 03:17:02 +00:00
},
),
migrations.CreateModel(
2022-10-25 04:57:34 +00:00
name='AppletHostDeployment',
2022-10-22 03:17:02 +00:00
fields=[
('created_by', models.CharField(blank=True, max_length=32, null=True, verbose_name='Created by')),
('updated_by', models.CharField(blank=True, max_length=32, null=True, verbose_name='Updated by')),
('date_created', models.DateTimeField(auto_now_add=True, null=True, verbose_name='Date created')),
('date_updated', models.DateTimeField(auto_now=True, verbose_name='Date updated')),
('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False)),
2022-11-01 03:52:51 +00:00
('status', models.CharField(max_length=16, default='', verbose_name='Status')),
2022-10-22 03:17:02 +00:00
('comment', models.TextField(blank=True, default='', verbose_name='Comment')),
2022-10-25 04:57:34 +00:00
('host', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='terminal.applethost', verbose_name='Hosting')),
2022-10-22 03:17:02 +00:00
],
options={
2022-10-25 04:57:34 +00:00
'abstract': False,
2022-10-22 03:17:02 +00:00
},
),
migrations.AddField(
2022-10-25 04:57:34 +00:00
model_name='applethost',
2022-10-22 03:17:02 +00:00
name='applets',
field=models.ManyToManyField(through='terminal.AppletPublication', to='terminal.Applet', verbose_name='Applet'),
),
]