Skip to content

Commit 7f121f7

Browse files
Merge pull request #6739 from netbox-community/6471-reset-migrations
Closes #6471: Squash database migrations up to v2.11.0
2 parents fe1f221 + 42b2e27 commit 7f121f7

File tree

322 files changed

+2791
-12762
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

322 files changed

+2791
-12762
lines changed

netbox/circuits/migrations/0001_initial.py

-62
This file was deleted.
+107
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,107 @@
1+
import dcim.fields
2+
import django.core.serializers.json
3+
from django.db import migrations, models
4+
import django.db.models.deletion
5+
6+
7+
class Migration(migrations.Migration):
8+
9+
initial = True
10+
11+
dependencies = [
12+
]
13+
14+
replaces = [
15+
('circuits', '0001_initial'),
16+
]
17+
18+
operations = [
19+
migrations.CreateModel(
20+
name='Circuit',
21+
fields=[
22+
('created', models.DateField(auto_now_add=True, null=True)),
23+
('last_updated', models.DateTimeField(auto_now=True, null=True)),
24+
('custom_field_data', models.JSONField(blank=True, default=dict, encoder=django.core.serializers.json.DjangoJSONEncoder)),
25+
('id', models.BigAutoField(primary_key=True, serialize=False)),
26+
('cid', models.CharField(max_length=100)),
27+
('status', models.CharField(default='active', max_length=50)),
28+
('install_date', models.DateField(blank=True, null=True)),
29+
('commit_rate', models.PositiveIntegerField(blank=True, null=True)),
30+
('description', models.CharField(blank=True, max_length=200)),
31+
('comments', models.TextField(blank=True)),
32+
],
33+
options={
34+
'ordering': ['provider', 'cid'],
35+
},
36+
),
37+
migrations.CreateModel(
38+
name='CircuitTermination',
39+
fields=[
40+
('created', models.DateField(auto_now_add=True, null=True)),
41+
('last_updated', models.DateTimeField(auto_now=True, null=True)),
42+
('id', models.BigAutoField(primary_key=True, serialize=False)),
43+
('_cable_peer_id', models.PositiveIntegerField(blank=True, null=True)),
44+
('mark_connected', models.BooleanField(default=False)),
45+
('term_side', models.CharField(max_length=1)),
46+
('port_speed', models.PositiveIntegerField(blank=True, null=True)),
47+
('upstream_speed', models.PositiveIntegerField(blank=True, null=True)),
48+
('xconnect_id', models.CharField(blank=True, max_length=50)),
49+
('pp_info', models.CharField(blank=True, max_length=100)),
50+
('description', models.CharField(blank=True, max_length=200)),
51+
],
52+
options={
53+
'ordering': ['circuit', 'term_side'],
54+
},
55+
),
56+
migrations.CreateModel(
57+
name='CircuitType',
58+
fields=[
59+
('created', models.DateField(auto_now_add=True, null=True)),
60+
('last_updated', models.DateTimeField(auto_now=True, null=True)),
61+
('custom_field_data', models.JSONField(blank=True, default=dict, encoder=django.core.serializers.json.DjangoJSONEncoder)),
62+
('id', models.BigAutoField(primary_key=True, serialize=False)),
63+
('name', models.CharField(max_length=100, unique=True)),
64+
('slug', models.SlugField(max_length=100, unique=True)),
65+
('description', models.CharField(blank=True, max_length=200)),
66+
],
67+
options={
68+
'ordering': ['name'],
69+
},
70+
),
71+
migrations.CreateModel(
72+
name='Provider',
73+
fields=[
74+
('created', models.DateField(auto_now_add=True, null=True)),
75+
('last_updated', models.DateTimeField(auto_now=True, null=True)),
76+
('custom_field_data', models.JSONField(blank=True, default=dict, encoder=django.core.serializers.json.DjangoJSONEncoder)),
77+
('id', models.BigAutoField(primary_key=True, serialize=False)),
78+
('name', models.CharField(max_length=100, unique=True)),
79+
('slug', models.SlugField(max_length=100, unique=True)),
80+
('asn', dcim.fields.ASNField(blank=True, null=True)),
81+
('account', models.CharField(blank=True, max_length=30)),
82+
('portal_url', models.URLField(blank=True)),
83+
('noc_contact', models.TextField(blank=True)),
84+
('admin_contact', models.TextField(blank=True)),
85+
('comments', models.TextField(blank=True)),
86+
],
87+
options={
88+
'ordering': ['name'],
89+
},
90+
),
91+
migrations.CreateModel(
92+
name='ProviderNetwork',
93+
fields=[
94+
('created', models.DateField(auto_now_add=True, null=True)),
95+
('last_updated', models.DateTimeField(auto_now=True, null=True)),
96+
('custom_field_data', models.JSONField(blank=True, default=dict, encoder=django.core.serializers.json.DjangoJSONEncoder)),
97+
('id', models.BigAutoField(primary_key=True, serialize=False)),
98+
('name', models.CharField(max_length=100)),
99+
('description', models.CharField(blank=True, max_length=200)),
100+
('comments', models.TextField(blank=True)),
101+
('provider', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, related_name='networks', to='circuits.provider')),
102+
],
103+
options={
104+
'ordering': ('provider', 'name'),
105+
},
106+
),
107+
]

netbox/circuits/migrations/0002_auto_20160622_1821.py

-41
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,129 @@
1+
from django.db import migrations, models
2+
import django.db.models.deletion
3+
import taggit.managers
4+
5+
6+
class Migration(migrations.Migration):
7+
8+
dependencies = [
9+
('dcim', '0001_initial'),
10+
('contenttypes', '0002_remove_content_type_name'),
11+
('circuits', '0001_initial'),
12+
('extras', '0001_initial'),
13+
('tenancy', '0001_initial'),
14+
]
15+
16+
replaces = [
17+
('circuits', '0002_auto_20160622_1821'),
18+
('circuits', '0003_provider_32bit_asn_support'),
19+
('circuits', '0004_circuit_add_tenant'),
20+
('circuits', '0005_circuit_add_upstream_speed'),
21+
('circuits', '0006_terminations'),
22+
('circuits', '0007_circuit_add_description'),
23+
('circuits', '0008_circuittermination_interface_protect_on_delete'),
24+
('circuits', '0009_unicode_literals'),
25+
('circuits', '0010_circuit_status'),
26+
('circuits', '0011_tags'),
27+
('circuits', '0012_change_logging'),
28+
('circuits', '0013_cables'),
29+
('circuits', '0014_circuittermination_description'),
30+
('circuits', '0015_custom_tag_models'),
31+
('circuits', '0016_3569_circuit_fields'),
32+
('circuits', '0017_circuittype_description'),
33+
('circuits', '0018_standardize_description'),
34+
('circuits', '0019_nullbooleanfield_to_booleanfield'),
35+
('circuits', '0020_custom_field_data'),
36+
('circuits', '0021_cache_cable_peer'),
37+
('circuits', '0022_cablepath'),
38+
('circuits', '0023_circuittermination_port_speed_optional'),
39+
('circuits', '0024_standardize_name_length'),
40+
('circuits', '0025_standardize_models'),
41+
('circuits', '0026_mark_connected'),
42+
('circuits', '0027_providernetwork'),
43+
('circuits', '0028_cache_circuit_terminations'),
44+
('circuits', '0029_circuit_tracing'),
45+
]
46+
47+
operations = [
48+
migrations.AddField(
49+
model_name='providernetwork',
50+
name='tags',
51+
field=taggit.managers.TaggableManager(through='extras.TaggedItem', to='extras.Tag'),
52+
),
53+
migrations.AddField(
54+
model_name='provider',
55+
name='tags',
56+
field=taggit.managers.TaggableManager(through='extras.TaggedItem', to='extras.Tag'),
57+
),
58+
migrations.AddField(
59+
model_name='circuittermination',
60+
name='_cable_peer_type',
61+
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to='contenttypes.contenttype'),
62+
),
63+
migrations.AddField(
64+
model_name='circuittermination',
65+
name='cable',
66+
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to='dcim.cable'),
67+
),
68+
migrations.AddField(
69+
model_name='circuittermination',
70+
name='circuit',
71+
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='terminations', to='circuits.circuit'),
72+
),
73+
migrations.AddField(
74+
model_name='circuittermination',
75+
name='provider_network',
76+
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.PROTECT, related_name='circuit_terminations', to='circuits.providernetwork'),
77+
),
78+
migrations.AddField(
79+
model_name='circuittermination',
80+
name='site',
81+
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.PROTECT, related_name='circuit_terminations', to='dcim.site'),
82+
),
83+
migrations.AddField(
84+
model_name='circuit',
85+
name='provider',
86+
field=models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, related_name='circuits', to='circuits.provider'),
87+
),
88+
migrations.AddField(
89+
model_name='circuit',
90+
name='tags',
91+
field=taggit.managers.TaggableManager(through='extras.TaggedItem', to='extras.Tag'),
92+
),
93+
migrations.AddField(
94+
model_name='circuit',
95+
name='tenant',
96+
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.PROTECT, related_name='circuits', to='tenancy.tenant'),
97+
),
98+
migrations.AddField(
99+
model_name='circuit',
100+
name='termination_a',
101+
field=models.ForeignKey(blank=True, editable=False, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to='circuits.circuittermination'),
102+
),
103+
migrations.AddField(
104+
model_name='circuit',
105+
name='termination_z',
106+
field=models.ForeignKey(blank=True, editable=False, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to='circuits.circuittermination'),
107+
),
108+
migrations.AddField(
109+
model_name='circuit',
110+
name='type',
111+
field=models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, related_name='circuits', to='circuits.circuittype'),
112+
),
113+
migrations.AddConstraint(
114+
model_name='providernetwork',
115+
constraint=models.UniqueConstraint(fields=('provider', 'name'), name='circuits_providernetwork_provider_name'),
116+
),
117+
migrations.AlterUniqueTogether(
118+
name='providernetwork',
119+
unique_together={('provider', 'name')},
120+
),
121+
migrations.AlterUniqueTogether(
122+
name='circuittermination',
123+
unique_together={('circuit', 'term_side')},
124+
),
125+
migrations.AlterUniqueTogether(
126+
name='circuit',
127+
unique_together={('provider', 'cid')},
128+
),
129+
]

netbox/circuits/migrations/0003_provider_32bit_asn_support.py

-19
This file was deleted.

netbox/circuits/migrations/0004_circuit_add_tenant.py

-20
This file was deleted.

0 commit comments

Comments
 (0)