mirror of
https://github.com/netbox-community/netbox.git
synced 2026-04-06 00:32:08 +02:00
Add migration files for indexes
This commit is contained in:
35
netbox/circuits/migrations/0057_default_ordering_indexes.py
Normal file
35
netbox/circuits/migrations/0057_default_ordering_indexes.py
Normal file
@@ -0,0 +1,35 @@
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
dependencies = [
|
||||
('circuits', '0056_gfk_indexes'),
|
||||
('contenttypes', '0002_remove_content_type_name'),
|
||||
('dcim', '0230_interface_rf_channel_frequency_precision'),
|
||||
('extras', '0136_customfield_validation_schema'),
|
||||
('tenancy', '0023_add_mptt_tree_indexes'),
|
||||
('users', '0015_owner'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddIndex(
|
||||
model_name='circuit',
|
||||
index=models.Index(fields=['provider', 'provider_account', 'cid'], name='circuits_ci_provide_a0c42c_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='circuitgroupassignment',
|
||||
index=models.Index(
|
||||
fields=['group', 'member_type', 'member_id', 'priority', 'id'], name='circuits_ci_group_i_2f8327_idx'
|
||||
),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='virtualcircuit',
|
||||
index=models.Index(
|
||||
fields=['provider_network', 'provider_account', 'cid'], name='circuits_vi_provide_989efa_idx'
|
||||
),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='virtualcircuittermination',
|
||||
index=models.Index(fields=['virtual_circuit', 'role', 'id'], name='circuits_vi_virtual_4b5c0c_idx'),
|
||||
),
|
||||
]
|
||||
21
netbox/core/migrations/0022_default_ordering_indexes.py
Normal file
21
netbox/core/migrations/0022_default_ordering_indexes.py
Normal file
@@ -0,0 +1,21 @@
|
||||
from django.conf import settings
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
dependencies = [
|
||||
('contenttypes', '0002_remove_content_type_name'),
|
||||
('core', '0021_job_queue_name'),
|
||||
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddIndex(
|
||||
model_name='configrevision',
|
||||
index=models.Index(fields=['-created'], name='core_config_created_ef9552_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='job',
|
||||
index=models.Index(fields=['-created'], name='core_job_created_efa7cb_idx'),
|
||||
),
|
||||
]
|
||||
78
netbox/dcim/migrations/0231_default_ordering_indexes.py
Normal file
78
netbox/dcim/migrations/0231_default_ordering_indexes.py
Normal file
@@ -0,0 +1,78 @@
|
||||
from django.conf import settings
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
dependencies = [
|
||||
('contenttypes', '0002_remove_content_type_name'),
|
||||
('dcim', '0230_interface_rf_channel_frequency_precision'),
|
||||
('extras', '0136_customfield_validation_schema'),
|
||||
('ipam', '0088_rename_vlangroup_total_vlan_ids'),
|
||||
('tenancy', '0023_add_mptt_tree_indexes'),
|
||||
('users', '0015_owner'),
|
||||
('virtualization', '0054_virtualmachinetype'),
|
||||
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddIndex(
|
||||
model_name='consoleporttemplate',
|
||||
index=models.Index(fields=['device_type', 'module_type', 'name'], name='dcim_consol_device__101ed5_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='consoleserverporttemplate',
|
||||
index=models.Index(fields=['device_type', 'module_type', 'name'], name='dcim_consol_device__a901e6_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='device',
|
||||
index=models.Index(fields=['name', 'id'], name='dcim_device_name_c27913_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='frontporttemplate',
|
||||
index=models.Index(fields=['device_type', 'module_type', 'name'], name='dcim_frontp_device__ec2ffb_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='interfacetemplate',
|
||||
index=models.Index(fields=['device_type', 'module_type', 'name'], name='dcim_interf_device__601012_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='macaddress',
|
||||
index=models.Index(fields=['mac_address', 'id'], name='dcim_macadd_mac_add_f2662a_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='modulebaytemplate',
|
||||
index=models.Index(fields=['device_type', 'module_type', 'name'], name='dcim_module_device__9eabad_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='moduletype',
|
||||
index=models.Index(fields=['profile', 'manufacturer', 'model'], name='dcim_module_profile_868277_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='poweroutlettemplate',
|
||||
index=models.Index(fields=['device_type', 'module_type', 'name'], name='dcim_powero_device__b83a8f_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='powerporttemplate',
|
||||
index=models.Index(fields=['device_type', 'module_type', 'name'], name='dcim_powerp_device__6c25da_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='rack',
|
||||
index=models.Index(fields=['site', 'location', 'name', 'id'], name='dcim_rack_site_id_715040_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='rackreservation',
|
||||
index=models.Index(fields=['created', 'id'], name='dcim_rackre_created_84f02e_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='rearporttemplate',
|
||||
index=models.Index(fields=['device_type', 'module_type', 'name'], name='dcim_rearpo_device__27f194_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='virtualchassis',
|
||||
index=models.Index(fields=['name'], name='dcim_virtua_name_2dc5cd_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='virtualdevicecontext',
|
||||
index=models.Index(fields=['name'], name='dcim_virtua_name_079d4d_idx'),
|
||||
),
|
||||
]
|
||||
74
netbox/extras/migrations/0137_default_ordering_indexes.py
Normal file
74
netbox/extras/migrations/0137_default_ordering_indexes.py
Normal file
@@ -0,0 +1,74 @@
|
||||
from django.conf import settings
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
dependencies = [
|
||||
('contenttypes', '0002_remove_content_type_name'),
|
||||
('core', '0022_default_ordering_indexes'),
|
||||
('dcim', '0231_default_ordering_indexes'),
|
||||
('extras', '0136_customfield_validation_schema'),
|
||||
('tenancy', '0023_add_mptt_tree_indexes'),
|
||||
('users', '0015_owner'),
|
||||
('virtualization', '0054_virtualmachinetype'),
|
||||
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddIndex(
|
||||
model_name='bookmark',
|
||||
index=models.Index(fields=['created', 'id'], name='extras_book_created_1cb4a5_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='configcontext',
|
||||
index=models.Index(fields=['weight', 'name'], name='extras_conf_weight_ef9a81_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='configtemplate',
|
||||
index=models.Index(fields=['name'], name='extras_conf_name_e276bf_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='customfield',
|
||||
index=models.Index(fields=['group_name', 'weight', 'name'], name='extras_cust_group_n_40cb93_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='customlink',
|
||||
index=models.Index(fields=['group_name', 'weight', 'name'], name='extras_cust_group_n_5a8be0_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='exporttemplate',
|
||||
index=models.Index(fields=['name'], name='extras_expo_name_55a9af_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='imageattachment',
|
||||
index=models.Index(fields=['name', 'id'], name='extras_imag_name_23cd9f_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='journalentry',
|
||||
index=models.Index(fields=['-created'], name='extras_jour_created_ec0fac_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='notification',
|
||||
index=models.Index(fields=['-created', 'id'], name='extras_noti_created_1d5146_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='savedfilter',
|
||||
index=models.Index(fields=['weight', 'name'], name='extras_save_weight_c070c4_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='script',
|
||||
index=models.Index(fields=['module', 'name'], name='extras_scri_module__8bd99c_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='subscription',
|
||||
index=models.Index(fields=['-created', 'user'], name='extras_subs_created_034618_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='tableconfig',
|
||||
index=models.Index(fields=['weight', 'name'], name='extras_tabl_weight_7c4bb6_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='tag',
|
||||
index=models.Index(fields=['weight', 'name'], name='extras_tag_weight_d99f50_idx'),
|
||||
),
|
||||
]
|
||||
47
netbox/ipam/migrations/0089_default_ordering_indexes.py
Normal file
47
netbox/ipam/migrations/0089_default_ordering_indexes.py
Normal file
@@ -0,0 +1,47 @@
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
dependencies = [
|
||||
('contenttypes', '0002_remove_content_type_name'),
|
||||
('dcim', '0231_default_ordering_indexes'),
|
||||
('extras', '0137_default_ordering_indexes'),
|
||||
('ipam', '0088_rename_vlangroup_total_vlan_ids'),
|
||||
('tenancy', '0023_add_mptt_tree_indexes'),
|
||||
('users', '0015_owner'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddIndex(
|
||||
model_name='aggregate',
|
||||
index=models.Index(fields=['prefix', 'id'], name='ipam_aggreg_prefix_89dd71_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='fhrpgroup',
|
||||
index=models.Index(fields=['protocol', 'group_id', 'id'], name='ipam_fhrpgr_protoco_0445ae_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='fhrpgroupassignment',
|
||||
index=models.Index(fields=['-priority', 'id'], name='ipam_fhrpgr_priorit_b76335_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='ipaddress',
|
||||
index=models.Index(fields=['address', 'id'], name='ipam_ipaddr_address_3ddeea_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='role',
|
||||
index=models.Index(fields=['weight', 'name'], name='ipam_role_weight_01396b_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='service',
|
||||
index=models.Index(fields=['protocol', 'ports', 'id'], name='ipam_servic_protoco_687d13_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='vlan',
|
||||
index=models.Index(fields=['site', 'group', 'vid', 'id'], name='ipam_vlan_site_id_985573_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='vrf',
|
||||
index=models.Index(fields=['name', 'rd', 'id'], name='ipam_vrf_name_ec911d_idx'),
|
||||
),
|
||||
]
|
||||
21
netbox/tenancy/migrations/0024_default_ordering_indexes.py
Normal file
21
netbox/tenancy/migrations/0024_default_ordering_indexes.py
Normal file
@@ -0,0 +1,21 @@
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
dependencies = [
|
||||
('contenttypes', '0002_remove_content_type_name'),
|
||||
('extras', '0137_default_ordering_indexes'),
|
||||
('tenancy', '0023_add_mptt_tree_indexes'),
|
||||
('users', '0015_owner'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddIndex(
|
||||
model_name='contact',
|
||||
index=models.Index(fields=['name'], name='tenancy_con_name_c26153_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='contactassignment',
|
||||
index=models.Index(fields=['contact', 'priority', 'role', 'id'], name='tenancy_con_contact_23011f_idx'),
|
||||
),
|
||||
]
|
||||
19
netbox/users/migrations/0016_default_ordering_indexes.py
Normal file
19
netbox/users/migrations/0016_default_ordering_indexes.py
Normal file
@@ -0,0 +1,19 @@
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
dependencies = [
|
||||
('contenttypes', '0002_remove_content_type_name'),
|
||||
('users', '0015_owner'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddIndex(
|
||||
model_name='objectpermission',
|
||||
index=models.Index(fields=['name'], name='users_objec_name_ca707b_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='token',
|
||||
index=models.Index(fields=['-created'], name='users_token_created_1467b4_idx'),
|
||||
),
|
||||
]
|
||||
@@ -0,0 +1,23 @@
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
dependencies = [
|
||||
('dcim', '0231_default_ordering_indexes'),
|
||||
('extras', '0137_default_ordering_indexes'),
|
||||
('ipam', '0089_default_ordering_indexes'),
|
||||
('tenancy', '0024_default_ordering_indexes'),
|
||||
('users', '0016_default_ordering_indexes'),
|
||||
('virtualization', '0054_virtualmachinetype'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddIndex(
|
||||
model_name='virtualmachine',
|
||||
index=models.Index(fields=['name', 'id'], name='virtualizat_name_16033e_idx'),
|
||||
),
|
||||
migrations.AddIndex(
|
||||
model_name='virtualmachinetype',
|
||||
index=models.Index(fields=['name'], name='virtualizat_name_6cff11_idx'),
|
||||
),
|
||||
]
|
||||
17
netbox/vpn/migrations/0012_default_ordering_indexes.py
Normal file
17
netbox/vpn/migrations/0012_default_ordering_indexes.py
Normal file
@@ -0,0 +1,17 @@
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
dependencies = [
|
||||
('contenttypes', '0002_remove_content_type_name'),
|
||||
('extras', '0137_default_ordering_indexes'),
|
||||
('ipam', '0089_default_ordering_indexes'),
|
||||
('vpn', '0011_add_comments_to_organizationalmodel'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddIndex(
|
||||
model_name='tunneltermination',
|
||||
index=models.Index(fields=['tunnel', 'role', 'id'], name='vpn_tunnelt_tunnel__f542d3_idx'),
|
||||
),
|
||||
]
|
||||
20
netbox/wireless/migrations/0019_default_ordering_indexes.py
Normal file
20
netbox/wireless/migrations/0019_default_ordering_indexes.py
Normal file
@@ -0,0 +1,20 @@
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
dependencies = [
|
||||
('contenttypes', '0002_remove_content_type_name'),
|
||||
('dcim', '0231_default_ordering_indexes'),
|
||||
('extras', '0137_default_ordering_indexes'),
|
||||
('ipam', '0089_default_ordering_indexes'),
|
||||
('tenancy', '0024_default_ordering_indexes'),
|
||||
('users', '0016_default_ordering_indexes'),
|
||||
('wireless', '0018_add_mptt_tree_indexes'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddIndex(
|
||||
model_name='wirelesslan',
|
||||
index=models.Index(fields=['ssid', 'id'], name='wireless_wi_ssid_64a9ce_idx'),
|
||||
),
|
||||
]
|
||||
Reference in New Issue
Block a user