From 2804d89c5ef00e6f11b4469e026be85c0fc074a2 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Fri, 17 Aug 2018 14:26:50 -0400 Subject: [PATCH 01/16] Fixes #2368: Record change in device changelog when altering cluster assignment --- netbox/virtualization/views.py | 27 ++++++++++++++++++--------- 1 file changed, 18 insertions(+), 9 deletions(-) diff --git a/netbox/virtualization/views.py b/netbox/virtualization/views.py index 4ddacce40..d4728da45 100644 --- a/netbox/virtualization/views.py +++ b/netbox/virtualization/views.py @@ -2,6 +2,7 @@ from __future__ import unicode_literals from django.contrib import messages from django.contrib.auth.mixins import PermissionRequiredMixin +from django.db import transaction from django.db.models import Count from django.shortcuts import get_object_or_404, redirect, render from django.urls import reverse @@ -183,17 +184,21 @@ class ClusterAddDevicesView(PermissionRequiredMixin, View): if form.is_valid(): - # Assign the selected Devices to the Cluster - devices = form.cleaned_data['devices'] - Device.objects.filter(pk__in=devices).update(cluster=cluster) + device_pks = form.cleaned_data['devices'] + with transaction.atomic(): + + # Assign the selected Devices to the Cluster + for device in Device.objects.filter(pk__in=device_pks): + device.cluster = cluster + device.save() messages.success(request, "Added {} devices to cluster {}".format( - len(devices), cluster + len(device_pks), cluster )) return redirect(cluster.get_absolute_url()) return render(request, self.template_name, { - 'cluser': cluster, + 'cluster': cluster, 'form': form, 'return_url': cluster.get_absolute_url(), }) @@ -212,12 +217,16 @@ class ClusterRemoveDevicesView(PermissionRequiredMixin, View): form = self.form(request.POST) if form.is_valid(): - # Remove the selected Devices from the Cluster - devices = form.cleaned_data['pk'] - Device.objects.filter(pk__in=devices).update(cluster=None) + device_pks = form.cleaned_data['pk'] + with transaction.atomic(): + + # Remove the selected Devices from the Cluster + for device in Device.objects.filter(pk__in=device_pks): + device.cluster = None + device.save() messages.success(request, "Removed {} devices from cluster {}".format( - len(devices), cluster + len(device_pks), cluster )) return redirect(cluster.get_absolute_url()) From d46b3e2446031463cf9a6273acc827f60b6d53b5 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Fri, 17 Aug 2018 14:32:51 -0400 Subject: [PATCH 02/16] #2368: Append changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5f164f4c1..4b742ba9c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,7 @@ v2.4.4 (FUTURE) ## Bug Fixes * [#2355](https://github.com/digitalocean/netbox/issues/2355) - Added item count to inventory tab on device view +* [#2368](https://github.com/digitalocean/netbox/issues/2368) - Record change in device changelog when altering cluster assignment --- From bc4997924393dff18fca4adb7bc6da781956b506 Mon Sep 17 00:00:00 2001 From: John Anderson Date: Fri, 17 Aug 2018 18:37:48 -0400 Subject: [PATCH 03/16] added rack group search #2254 --- netbox/dcim/filters.py | 13 +++++++++++++ netbox/netbox/forms.py | 1 + netbox/netbox/views.py | 19 ++++++++++++++++--- 3 files changed, 30 insertions(+), 3 deletions(-) diff --git a/netbox/dcim/filters.py b/netbox/dcim/filters.py index 18a0039e6..c81af4478 100644 --- a/netbox/dcim/filters.py +++ b/netbox/dcim/filters.py @@ -112,6 +112,10 @@ class SiteFilter(CustomFieldFilterSet, django_filters.FilterSet): class RackGroupFilter(django_filters.FilterSet): + q = django_filters.CharFilter( + method='search', + label='Search', + ) site_id = django_filters.ModelMultipleChoiceFilter( queryset=Site.objects.all(), label='Site (ID)', @@ -127,6 +131,15 @@ class RackGroupFilter(django_filters.FilterSet): model = RackGroup fields = ['site_id', 'name', 'slug'] + def search(self, queryset, name, value): + if not value.strip(): + return queryset + qs_filter = ( + Q(name__icontains=value) | + Q(slug__icontains=value) + ) + return queryset.filter(qs_filter) + class RackRoleFilter(django_filters.FilterSet): diff --git a/netbox/netbox/forms.py b/netbox/netbox/forms.py index 5611f49f9..434377024 100644 --- a/netbox/netbox/forms.py +++ b/netbox/netbox/forms.py @@ -13,6 +13,7 @@ OBJ_TYPE_CHOICES = ( ('DCIM', ( ('site', 'Sites'), ('rack', 'Racks'), + ('rackgroup', 'Rack Groups'), ('devicetype', 'Device types'), ('device', 'Devices'), ('virtualchassis', 'Virtual Chassis'), diff --git a/netbox/netbox/views.py b/netbox/netbox/views.py index 1e3433016..c6814c068 100644 --- a/netbox/netbox/views.py +++ b/netbox/netbox/views.py @@ -12,9 +12,16 @@ from rest_framework.views import APIView from circuits.filters import CircuitFilter, ProviderFilter from circuits.models import Circuit, Provider from circuits.tables import CircuitTable, ProviderTable -from dcim.filters import DeviceFilter, DeviceTypeFilter, RackFilter, SiteFilter, VirtualChassisFilter -from dcim.models import ConsolePort, Device, DeviceType, InterfaceConnection, PowerPort, Rack, Site, VirtualChassis -from dcim.tables import DeviceDetailTable, DeviceTypeTable, RackTable, SiteTable, VirtualChassisTable +from dcim.filters import ( + DeviceFilter, DeviceTypeFilter, RackFilter, RackGroupFilter, SiteFilter, VirtualChassisFilter +) +from dcim.models import ( + ConsolePort, Device, DeviceType, InterfaceConnection, PowerPort, Rack, RackGroup, Site, + VirtualChassis +) +from dcim.tables import ( + DeviceDetailTable, DeviceTypeTable, RackTable, RackGroupTable, SiteTable, VirtualChassisTable +) from extras.models import ObjectChange, ReportResult, TopologyMap from ipam.filters import AggregateFilter, IPAddressFilter, PrefixFilter, VLANFilter, VRFFilter from ipam.models import Aggregate, IPAddress, Prefix, VLAN, VRF @@ -58,6 +65,12 @@ SEARCH_TYPES = OrderedDict(( 'table': RackTable, 'url': 'dcim:rack_list', }), + ('rackgroup', { + 'queryset': RackGroup.objects.select_related('site').annotate(rack_count=Count('racks')), + 'filter': RackGroupFilter, + 'table': RackGroupTable, + 'url': 'dcim:rackgroup_list', + }), ('devicetype', { 'queryset': DeviceType.objects.select_related('manufacturer').annotate(instance_count=Count('instances')), 'filter': DeviceTypeFilter, From 771747147ce4e7d36c6f7979d93385203450eb14 Mon Sep 17 00:00:00 2001 From: John Anderson Date: Fri, 17 Aug 2018 18:41:58 -0400 Subject: [PATCH 04/16] #2254 changelog entry --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4b742ba9c..ba04b9300 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,7 @@ v2.4.4 (FUTURE) * [#2356](https://github.com/digitalocean/netbox/issues/2356) - Include cluster site as read-only field in VirtualMachine serializer * [#2362](https://github.com/digitalocean/netbox/issues/2362) - Implemented custom admin site to properly handle BASE_PATH +* [#2254](https://github.com/digitalocean/netbox/issues/2254) - Implemented searchability for Rack Groups ## Bug Fixes From 9e5b482b1d267e1f34a1fd76c4fb35ba5c1db93b Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Mon, 20 Aug 2018 13:36:42 -0400 Subject: [PATCH 05/16] Fixes #2374: Fix toggling display of IP addresses in virtual machine interfaces list --- CHANGELOG.md | 1 + netbox/templates/virtualization/virtualmachine.html | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ba04b9300..bacb10c36 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,7 @@ v2.4.4 (FUTURE) * [#2355](https://github.com/digitalocean/netbox/issues/2355) - Added item count to inventory tab on device view * [#2368](https://github.com/digitalocean/netbox/issues/2368) - Record change in device changelog when altering cluster assignment +* [#2374](https://github.com/digitalocean/netbox/issues/2374) - Fix toggling display of IP addresses in virtual machine interfaces list --- diff --git a/netbox/templates/virtualization/virtualmachine.html b/netbox/templates/virtualization/virtualmachine.html index e3b092ba8..552aaa997 100644 --- a/netbox/templates/virtualization/virtualmachine.html +++ b/netbox/templates/virtualization/virtualmachine.html @@ -315,9 +315,9 @@ $('button.toggle-ips').click(function() { var selected = $(this).attr('selected'); if (selected) { - $('#interfaces_table tr.ipaddress').hide(); + $('#interfaces_table tr.ipaddresses').hide(); } else { - $('#interfaces_table tr.ipaddress').show(); + $('#interfaces_table tr.ipaddresses').show(); } $(this).attr('selected', !selected); $(this).children('span').toggleClass('glyphicon-check glyphicon-unchecked'); From c333af33dc117ecbc51ae0bee6de46e9ab347460 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Mon, 20 Aug 2018 14:40:19 -0400 Subject: [PATCH 06/16] Fixes #2370: Redirect to parent device after deleting device bays --- CHANGELOG.md | 1 + netbox/templates/dcim/device.html | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index bacb10c36..f5289f036 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,7 @@ v2.4.4 (FUTURE) * [#2355](https://github.com/digitalocean/netbox/issues/2355) - Added item count to inventory tab on device view * [#2368](https://github.com/digitalocean/netbox/issues/2368) - Record change in device changelog when altering cluster assignment +* [#2370](https://github.com/digitalocean/netbox/issues/2370) - Redirect to parent device after deleting device bays * [#2374](https://github.com/digitalocean/netbox/issues/2374) - Fix toggling display of IP addresses in virtual machine interfaces list --- diff --git a/netbox/templates/dcim/device.html b/netbox/templates/dcim/device.html index 4852823b7..7b56269b1 100644 --- a/netbox/templates/dcim/device.html +++ b/netbox/templates/dcim/device.html @@ -447,7 +447,7 @@
{% if device_bays or device.device_type.is_parent_device %} {% if perms.dcim.delete_devicebay %} -
+ {% csrf_token %} {% endif %}
@@ -483,7 +483,7 @@ {% endif %} {% if device_bays and perms.dcim.delete_devicebay %} - {% endif %} From e1e41a768a528586ac2a27000426240844372f34 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Mon, 20 Aug 2018 16:53:23 -0400 Subject: [PATCH 07/16] Fixes #2369: Corrected time zone validation on site API serializer --- CHANGELOG.md | 1 + netbox/utilities/api.py | 7 +++---- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f5289f036..2609cb23b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,7 @@ v2.4.4 (FUTURE) * [#2355](https://github.com/digitalocean/netbox/issues/2355) - Added item count to inventory tab on device view * [#2368](https://github.com/digitalocean/netbox/issues/2368) - Record change in device changelog when altering cluster assignment +* [#2369](https://github.com/digitalocean/netbox/issues/2369) - Corrected time zone validation on site API serializer * [#2370](https://github.com/digitalocean/netbox/issues/2370) - Redirect to parent device after deleting device bays * [#2374](https://github.com/digitalocean/netbox/issues/2374) - Fix toggling display of IP addresses in virtual machine interfaces list diff --git a/netbox/utilities/api.py b/netbox/utilities/api.py index f7d4293a7..e3011caf4 100644 --- a/netbox/utilities/api.py +++ b/netbox/utilities/api.py @@ -108,10 +108,9 @@ class TimeZoneField(Field): def to_internal_value(self, data): if not data: return "" - try: - return pytz.timezone(str(data)) - except pytz.exceptions.UnknownTimeZoneError: - raise ValidationError('Invalid time zone "{}"'.format(data)) + if data not in pytz.common_timezones: + raise ValidationError('Unknown time zone "{}" (see pytz.common_timezones for all options)'.format(data)) + return pytz.timezone(data) class SerializedPKRelatedField(PrimaryKeyRelatedField): From 118b8db2094324c5af4715ac02a49e63d84a7e24 Mon Sep 17 00:00:00 2001 From: Jimmy Taylor Date: Tue, 21 Aug 2018 08:28:23 -0600 Subject: [PATCH 08/16] Fixed typo for supervisorctl --- docs/configuration/index.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/configuration/index.md b/docs/configuration/index.md index 97857a4c4..619af171c 100644 --- a/docs/configuration/index.md +++ b/docs/configuration/index.md @@ -12,5 +12,5 @@ While NetBox has many configuration settings, only a few of them must be defined Configuration settings may be changed at any time. However, the NetBox service must be restarted before the changes will take effect: ```no-highlight -# sudo supervsiorctl restart netbox +# sudo supervisorctl restart netbox ``` From aa50e2e385b4731cce4053af754866c1e76233e9 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Wed, 22 Aug 2018 10:06:01 -0400 Subject: [PATCH 09/16] Fixes #2378: Corrected "edit" link for virtual machine interfaces --- CHANGELOG.md | 1 + netbox/templates/dcim/interface.html | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2609cb23b..3803653cf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,7 @@ v2.4.4 (FUTURE) * [#2369](https://github.com/digitalocean/netbox/issues/2369) - Corrected time zone validation on site API serializer * [#2370](https://github.com/digitalocean/netbox/issues/2370) - Redirect to parent device after deleting device bays * [#2374](https://github.com/digitalocean/netbox/issues/2374) - Fix toggling display of IP addresses in virtual machine interfaces list +* [#2378](https://github.com/digitalocean/netbox/issues/2378) - Corrected "edit" link for virtual machine interfaces --- diff --git a/netbox/templates/dcim/interface.html b/netbox/templates/dcim/interface.html index 2004af1b1..f82f81baf 100644 --- a/netbox/templates/dcim/interface.html +++ b/netbox/templates/dcim/interface.html @@ -17,12 +17,12 @@
{% if perms.dcim.change_interface %} - + Edit this interface {% endif %} {% if perms.dcim.delete_interface %} - + Delete this interface {% endif %} From 66400a98f18c4c22d4fddcf2f58bc6d5c44f71e5 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Wed, 22 Aug 2018 10:25:07 -0400 Subject: [PATCH 10/16] Fixes #2354: Increased maximum MTU for interfaces to 65536 bytes --- CHANGELOG.md | 1 + netbox/dcim/migrations/0062_interface_mtu.py | 19 +++++++++++++++++++ netbox/dcim/models.py | 3 ++- 3 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 netbox/dcim/migrations/0062_interface_mtu.py diff --git a/CHANGELOG.md b/CHANGELOG.md index 3803653cf..33cf21571 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,7 @@ v2.4.4 (FUTURE) ## Bug Fixes +* [#2354](https://github.com/digitalocean/netbox/issues/2354) - Increased maximum MTU for interfaces to 65536 bytes * [#2355](https://github.com/digitalocean/netbox/issues/2355) - Added item count to inventory tab on device view * [#2368](https://github.com/digitalocean/netbox/issues/2368) - Record change in device changelog when altering cluster assignment * [#2369](https://github.com/digitalocean/netbox/issues/2369) - Corrected time zone validation on site API serializer diff --git a/netbox/dcim/migrations/0062_interface_mtu.py b/netbox/dcim/migrations/0062_interface_mtu.py new file mode 100644 index 000000000..047f145d3 --- /dev/null +++ b/netbox/dcim/migrations/0062_interface_mtu.py @@ -0,0 +1,19 @@ +# Generated by Django 2.0.8 on 2018-08-22 14:23 + +import django.core.validators +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('dcim', '0061_platform_napalm_args'), + ] + + operations = [ + migrations.AlterField( + model_name='interface', + name='mtu', + field=models.PositiveIntegerField(blank=True, null=True, validators=[django.core.validators.MinValueValidator(1), django.core.validators.MaxValueValidator(65536)], verbose_name='MTU'), + ), + ] diff --git a/netbox/dcim/models.py b/netbox/dcim/models.py index 564e6fa74..cedad8bed 100644 --- a/netbox/dcim/models.py +++ b/netbox/dcim/models.py @@ -1809,9 +1809,10 @@ class Interface(ComponentModel): blank=True, verbose_name='MAC Address' ) - mtu = models.PositiveSmallIntegerField( + mtu = models.PositiveIntegerField( blank=True, null=True, + validators=[MinValueValidator(1), MaxValueValidator(65536)], verbose_name='MTU' ) mgmt_only = models.BooleanField( From dbbf7ab66453c96dad2b66434afe91e2ddba0291 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Wed, 22 Aug 2018 10:35:48 -0400 Subject: [PATCH 11/16] Fixes #2353: Handle DoesNotExist exception when deleting a device with connected interfaces --- CHANGELOG.md | 1 + netbox/dcim/models.py | 9 ++++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 33cf21571..c4b5df057 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,7 @@ v2.4.4 (FUTURE) ## Bug Fixes +* [#2353](https://github.com/digitalocean/netbox/issues/2353) - Handle `DoesNotExist` exception when deleting a device with connected interfaces * [#2354](https://github.com/digitalocean/netbox/issues/2354) - Increased maximum MTU for interfaces to 65536 bytes * [#2355](https://github.com/digitalocean/netbox/issues/2355) - Added item count to inventory tab on device view * [#2368](https://github.com/digitalocean/netbox/issues/2368) - Record change in device changelog when altering cluster assignment diff --git a/netbox/dcim/models.py b/netbox/dcim/models.py index cedad8bed..19c75bdb9 100644 --- a/netbox/dcim/models.py +++ b/netbox/dcim/models.py @@ -2072,6 +2072,7 @@ class InterfaceConnection(models.Model): (self.interface_a, self.interface_b), (self.interface_b, self.interface_a), ) + for interface, peer_interface in interfaces: if action == OBJECTCHANGE_ACTION_DELETE: connection_data = { @@ -2082,11 +2083,17 @@ class InterfaceConnection(models.Model): 'connected_interface': peer_interface.pk, 'connection_status': self.connection_status } + + try: + parent_obj = interface.parent + except ObjectDoesNotExist: + parent_obj = None + ObjectChange( user=user, request_id=request_id, changed_object=interface, - related_object=interface.parent, + related_object=parent_obj, action=OBJECTCHANGE_ACTION_UPDATE, object_data=serialize_object(interface, extra=connection_data) ).save() From ac363394913e76f135d68dca3d509762a7d092d0 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Wed, 22 Aug 2018 11:33:43 -0400 Subject: [PATCH 12/16] Closes #2168: Added Extreme SummitStack interface form factors --- CHANGELOG.md | 1 + netbox/dcim/constants.py | 9 +++++++++ netbox/dcim/migrations/0062_interface_mtu.py | 10 ++++++++++ 3 files changed, 20 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index c4b5df057..e7939406d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ v2.4.4 (FUTURE) ## Enhancements +* [#2168](https://github.com/digitalocean/netbox/issues/2168) - Added Extreme SummitStack interface form factors * [#2356](https://github.com/digitalocean/netbox/issues/2356) - Include cluster site as read-only field in VirtualMachine serializer * [#2362](https://github.com/digitalocean/netbox/issues/2362) - Implemented custom admin site to properly handle BASE_PATH * [#2254](https://github.com/digitalocean/netbox/issues/2254) - Implemented searchability for Rack Groups diff --git a/netbox/dcim/constants.py b/netbox/dcim/constants.py index cea56e176..c41259533 100644 --- a/netbox/dcim/constants.py +++ b/netbox/dcim/constants.py @@ -93,6 +93,11 @@ IFACE_FF_STACKWISE_PLUS = 5050 IFACE_FF_FLEXSTACK = 5100 IFACE_FF_FLEXSTACK_PLUS = 5150 IFACE_FF_JUNIPER_VCP = 5200 +IFACE_FF_SUMMITSTACK = 5300 +IFACE_FF_SUMMITSTACK128 = 5310 +IFACE_FF_SUMMITSTACK256 = 5320 +IFACE_FF_SUMMITSTACK512 = 5330 + # Other IFACE_FF_OTHER = 32767 @@ -168,6 +173,10 @@ IFACE_FF_CHOICES = [ [IFACE_FF_FLEXSTACK, 'Cisco FlexStack'], [IFACE_FF_FLEXSTACK_PLUS, 'Cisco FlexStack Plus'], [IFACE_FF_JUNIPER_VCP, 'Juniper VCP'], + [IFACE_FF_SUMMITSTACK, 'Extreme SummitStack'], + [IFACE_FF_SUMMITSTACK128, 'Extreme SummitStack-128'], + [IFACE_FF_SUMMITSTACK256, 'Extreme SummitStack-256'], + [IFACE_FF_SUMMITSTACK512, 'Extreme SummitStack-512'], ] ], [ diff --git a/netbox/dcim/migrations/0062_interface_mtu.py b/netbox/dcim/migrations/0062_interface_mtu.py index 047f145d3..592f11bb7 100644 --- a/netbox/dcim/migrations/0062_interface_mtu.py +++ b/netbox/dcim/migrations/0062_interface_mtu.py @@ -16,4 +16,14 @@ class Migration(migrations.Migration): name='mtu', field=models.PositiveIntegerField(blank=True, null=True, validators=[django.core.validators.MinValueValidator(1), django.core.validators.MaxValueValidator(65536)], verbose_name='MTU'), ), + migrations.AlterField( + model_name='interface', + name='form_factor', + field=models.PositiveSmallIntegerField(choices=[['Virtual interfaces', [[0, 'Virtual'], [200, 'Link Aggregation Group (LAG)']]], ['Ethernet (fixed)', [[800, '100BASE-TX (10/100ME)'], [1000, '1000BASE-T (1GE)'], [1150, '10GBASE-T (10GE)'], [1170, '10GBASE-CX4 (10GE)']]], ['Ethernet (modular)', [[1050, 'GBIC (1GE)'], [1100, 'SFP (1GE)'], [1200, 'SFP+ (10GE)'], [1300, 'XFP (10GE)'], [1310, 'XENPAK (10GE)'], [1320, 'X2 (10GE)'], [1350, 'SFP28 (25GE)'], [1400, 'QSFP+ (40GE)'], [1500, 'CFP (100GE)'], [1510, 'CFP2 (100GE)'], [1520, 'CFP4 (100GE)'], [1550, 'Cisco CPAK (100GE)'], [1600, 'QSFP28 (100GE)']]], ['Wireless', [[2600, 'IEEE 802.11a'], [2610, 'IEEE 802.11b/g'], [2620, 'IEEE 802.11n'], [2630, 'IEEE 802.11ac'], [2640, 'IEEE 802.11ad']]], ['FibreChannel', [[3010, 'SFP (1GFC)'], [3020, 'SFP (2GFC)'], [3040, 'SFP (4GFC)'], [3080, 'SFP+ (8GFC)'], [3160, 'SFP+ (16GFC)']]], ['Serial', [[4000, 'T1 (1.544 Mbps)'], [4010, 'E1 (2.048 Mbps)'], [4040, 'T3 (45 Mbps)'], [4050, 'E3 (34 Mbps)']]], ['Stacking', [[5000, 'Cisco StackWise'], [5050, 'Cisco StackWise Plus'], [5100, 'Cisco FlexStack'], [5150, 'Cisco FlexStack Plus'], [5200, 'Juniper VCP'], [5300, 'Extreme SummitStack'], [5310, 'Extreme SummitStack-128'], [5320, 'Extreme SummitStack-256'], [5330, 'Extreme SummitStack-512']]], ['Other', [[32767, 'Other']]]], default=1200), + ), + migrations.AlterField( + model_name='interfacetemplate', + name='form_factor', + field=models.PositiveSmallIntegerField(choices=[['Virtual interfaces', [[0, 'Virtual'], [200, 'Link Aggregation Group (LAG)']]], ['Ethernet (fixed)', [[800, '100BASE-TX (10/100ME)'], [1000, '1000BASE-T (1GE)'], [1150, '10GBASE-T (10GE)'], [1170, '10GBASE-CX4 (10GE)']]], ['Ethernet (modular)', [[1050, 'GBIC (1GE)'], [1100, 'SFP (1GE)'], [1200, 'SFP+ (10GE)'], [1300, 'XFP (10GE)'], [1310, 'XENPAK (10GE)'], [1320, 'X2 (10GE)'], [1350, 'SFP28 (25GE)'], [1400, 'QSFP+ (40GE)'], [1500, 'CFP (100GE)'], [1510, 'CFP2 (100GE)'], [1520, 'CFP4 (100GE)'], [1550, 'Cisco CPAK (100GE)'], [1600, 'QSFP28 (100GE)']]], ['Wireless', [[2600, 'IEEE 802.11a'], [2610, 'IEEE 802.11b/g'], [2620, 'IEEE 802.11n'], [2630, 'IEEE 802.11ac'], [2640, 'IEEE 802.11ad']]], ['FibreChannel', [[3010, 'SFP (1GFC)'], [3020, 'SFP (2GFC)'], [3040, 'SFP (4GFC)'], [3080, 'SFP+ (8GFC)'], [3160, 'SFP+ (16GFC)']]], ['Serial', [[4000, 'T1 (1.544 Mbps)'], [4010, 'E1 (2.048 Mbps)'], [4040, 'T3 (45 Mbps)'], [4050, 'E3 (34 Mbps)']]], ['Stacking', [[5000, 'Cisco StackWise'], [5050, 'Cisco StackWise Plus'], [5100, 'Cisco FlexStack'], [5150, 'Cisco FlexStack Plus'], [5200, 'Juniper VCP'], [5300, 'Extreme SummitStack'], [5310, 'Extreme SummitStack-128'], [5320, 'Extreme SummitStack-256'], [5330, 'Extreme SummitStack-512']]], ['Other', [[32767, 'Other']]]], default=1200), + ), ] From b917e8d3b0ae723e2eafc2ac69f77d800e2ee226 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Wed, 22 Aug 2018 11:46:13 -0400 Subject: [PATCH 13/16] #2376: Add libapache2-mod-wsgi-py3 to CentOS installation section --- docs/installation/3-http-daemon.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/installation/3-http-daemon.md b/docs/installation/3-http-daemon.md index 9ed8fdd74..6ca38783e 100644 --- a/docs/installation/3-http-daemon.md +++ b/docs/installation/3-http-daemon.md @@ -56,7 +56,7 @@ To enable SSL, consider this guide on [securing nginx with Let's Encrypt](https: ## Option B: Apache ```no-highlight -# apt-get install -y apache2 +# apt-get install -y apache2 libapache2-mod-wsgi-py3 ``` Once Apache is installed, proceed with the following configuration (Be sure to modify the `ServerName` appropriately): From f2d9a3e0a125861d909227ffba868326f455000f Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Wed, 22 Aug 2018 11:50:25 -0400 Subject: [PATCH 14/16] Added note about CHANGELOG to release checklist --- docs/development/release-checklist.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/development/release-checklist.md b/docs/development/release-checklist.md index cce096b48..5e1f92fcc 100644 --- a/docs/development/release-checklist.md +++ b/docs/development/release-checklist.md @@ -48,9 +48,9 @@ Close the release milestone on GitHub. Ensure that there are no remaining open i Ensure that continuous integration testing on the `develop` branch is completing successfully. -## Update VERSION +## Update Version and Changelog -Update the `VERSION` constant in `settings.py` to the new release. +Update the `VERSION` constant in `settings.py` to the new release version and add the current date to the release notes in `CHANGELOG.md`. ## Submit a Pull Request From cde6e9757b4239d54dbb28ed9e9eed58654c2df4 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Wed, 22 Aug 2018 11:51:15 -0400 Subject: [PATCH 15/16] Release v2.4.4 --- CHANGELOG.md | 2 +- netbox/netbox/settings.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e7939406d..e50be204f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,4 @@ -v2.4.4 (FUTURE) +v2.4.4 (2018-08-22) ## Enhancements diff --git a/netbox/netbox/settings.py b/netbox/netbox/settings.py index e449eec97..5d2426841 100644 --- a/netbox/netbox/settings.py +++ b/netbox/netbox/settings.py @@ -22,7 +22,7 @@ if sys.version_info[0] < 3: DeprecationWarning ) -VERSION = '2.4.4-dev' +VERSION = '2.4.4' BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) From 010765e1319001899c9d26d9c8cfe9fd52273634 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Wed, 22 Aug 2018 11:55:51 -0400 Subject: [PATCH 16/16] Post-release version bump --- netbox/netbox/settings.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/netbox/netbox/settings.py b/netbox/netbox/settings.py index 5d2426841..cdcc71069 100644 --- a/netbox/netbox/settings.py +++ b/netbox/netbox/settings.py @@ -22,7 +22,7 @@ if sys.version_info[0] < 3: DeprecationWarning ) -VERSION = '2.4.4' +VERSION = '2.4.5-dev' BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))