nautobot 2.1.8__py3-none-any.whl → 2.1.9__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of nautobot might be problematic. Click here for more details.

Files changed (296) hide show
  1. nautobot/apps/api.py +1 -2
  2. nautobot/apps/utils.py +4 -0
  3. nautobot/apps/views.py +2 -0
  4. nautobot/circuits/api/urls.py +1 -2
  5. nautobot/circuits/api/views.py +0 -12
  6. nautobot/core/api/routers.py +25 -3
  7. nautobot/core/api/utils.py +4 -0
  8. nautobot/core/api/views.py +21 -15
  9. nautobot/core/settings.py +1 -0
  10. nautobot/core/templates/admin/base.html +23 -94
  11. nautobot/core/templates/graphene/graphiql.html +18 -47
  12. nautobot/core/templates/inc/footer.html +5 -5
  13. nautobot/core/templates/inc/nav_menu.html +0 -7
  14. nautobot/core/templates/rest_framework/api.html +12 -5
  15. nautobot/core/tests/integration/test_view_authentication.py +67 -0
  16. nautobot/core/tests/test_graphql.py +2 -14
  17. nautobot/core/tests/test_views.py +22 -16
  18. nautobot/core/utils/lookup.py +124 -0
  19. nautobot/core/views/__init__.py +3 -7
  20. nautobot/core/views/generic.py +9 -0
  21. nautobot/dcim/api/urls.py +1 -2
  22. nautobot/dcim/api/views.py +1 -12
  23. nautobot/dcim/models/racks.py +1 -3
  24. nautobot/dcim/templates/dcim/device/lldp_neighbors.html +67 -43
  25. nautobot/dcim/tests/test_api.py +3 -0
  26. nautobot/dcim/views.py +5 -2
  27. nautobot/extras/api/urls.py +1 -2
  28. nautobot/extras/api/views.py +0 -10
  29. nautobot/extras/plugins/views.py +6 -9
  30. nautobot/extras/tests/test_views.py +101 -0
  31. nautobot/extras/views.py +10 -10
  32. nautobot/ipam/api/urls.py +1 -2
  33. nautobot/ipam/api/views.py +0 -11
  34. nautobot/ipam/tables.py +0 -1
  35. nautobot/ipam/tests/test_graphql.py +2 -3
  36. nautobot/ipam/views.py +9 -9
  37. nautobot/project-static/css/base.css +1 -0
  38. nautobot/project-static/docs/404.html +14 -0
  39. nautobot/project-static/docs/apps/index.html +14 -0
  40. nautobot/project-static/docs/apps/nautobot-apps.html +14 -0
  41. nautobot/project-static/docs/code-reference/nautobot/apps/__init__.html +14 -0
  42. nautobot/project-static/docs/code-reference/nautobot/apps/admin.html +14 -0
  43. nautobot/project-static/docs/code-reference/nautobot/apps/api.html +394 -408
  44. nautobot/project-static/docs/code-reference/nautobot/apps/change_logging.html +14 -0
  45. nautobot/project-static/docs/code-reference/nautobot/apps/choices.html +14 -0
  46. nautobot/project-static/docs/code-reference/nautobot/apps/config.html +14 -0
  47. nautobot/project-static/docs/code-reference/nautobot/apps/datasources.html +14 -0
  48. nautobot/project-static/docs/code-reference/nautobot/apps/exceptions.html +14 -0
  49. nautobot/project-static/docs/code-reference/nautobot/apps/factory.html +14 -0
  50. nautobot/project-static/docs/code-reference/nautobot/apps/filters.html +14 -0
  51. nautobot/project-static/docs/code-reference/nautobot/apps/forms.html +14 -0
  52. nautobot/project-static/docs/code-reference/nautobot/apps/graphql.html +14 -0
  53. nautobot/project-static/docs/code-reference/nautobot/apps/jobs.html +14 -0
  54. nautobot/project-static/docs/code-reference/nautobot/apps/models.html +14 -0
  55. nautobot/project-static/docs/code-reference/nautobot/apps/querysets.html +14 -0
  56. nautobot/project-static/docs/code-reference/nautobot/apps/secrets.html +14 -0
  57. nautobot/project-static/docs/code-reference/nautobot/apps/tables.html +14 -0
  58. nautobot/project-static/docs/code-reference/nautobot/apps/testing.html +14 -0
  59. nautobot/project-static/docs/code-reference/nautobot/apps/ui.html +14 -0
  60. nautobot/project-static/docs/code-reference/nautobot/apps/urls.html +14 -0
  61. nautobot/project-static/docs/code-reference/nautobot/apps/utils.html +649 -183
  62. nautobot/project-static/docs/code-reference/nautobot/apps/views.html +1811 -1744
  63. nautobot/project-static/docs/development/apps/api/configuration-view.html +14 -0
  64. nautobot/project-static/docs/development/apps/api/database-backend-config.html +14 -0
  65. nautobot/project-static/docs/development/apps/api/models/django-admin.html +14 -0
  66. nautobot/project-static/docs/development/apps/api/models/global-search.html +14 -0
  67. nautobot/project-static/docs/development/apps/api/models/graphql.html +14 -0
  68. nautobot/project-static/docs/development/apps/api/models/index.html +14 -0
  69. nautobot/project-static/docs/development/apps/api/nautobot-app-config.html +14 -0
  70. nautobot/project-static/docs/development/apps/api/platform-features/custom-validators.html +14 -0
  71. nautobot/project-static/docs/development/apps/api/platform-features/filter-extensions.html +14 -0
  72. nautobot/project-static/docs/development/apps/api/platform-features/git-repository-content.html +14 -0
  73. nautobot/project-static/docs/development/apps/api/platform-features/index.html +14 -0
  74. nautobot/project-static/docs/development/apps/api/platform-features/jinja2-filters.html +14 -0
  75. nautobot/project-static/docs/development/apps/api/platform-features/jobs.html +14 -0
  76. nautobot/project-static/docs/development/apps/api/platform-features/populating-extensibility-features.html +14 -0
  77. nautobot/project-static/docs/development/apps/api/platform-features/secrets-providers.html +14 -0
  78. nautobot/project-static/docs/development/apps/api/platform-features/uniquely-identify-objects.html +14 -0
  79. nautobot/project-static/docs/development/apps/api/prometheus.html +14 -0
  80. nautobot/project-static/docs/development/apps/api/setup.html +14 -0
  81. nautobot/project-static/docs/development/apps/api/testing.html +14 -0
  82. nautobot/project-static/docs/development/apps/api/ui-extensions/banners.html +14 -0
  83. nautobot/project-static/docs/development/apps/api/ui-extensions/home-page.html +14 -0
  84. nautobot/project-static/docs/development/apps/api/ui-extensions/index.html +14 -0
  85. nautobot/project-static/docs/development/apps/api/ui-extensions/navigation.html +14 -0
  86. nautobot/project-static/docs/development/apps/api/ui-extensions/object-views.html +14 -0
  87. nautobot/project-static/docs/development/apps/api/views/base-template.html +14 -0
  88. nautobot/project-static/docs/development/apps/api/views/core-view-overrides.html +28 -9
  89. nautobot/project-static/docs/development/apps/api/views/django-generic-views.html +31 -12
  90. nautobot/project-static/docs/development/apps/api/views/help-documentation.html +14 -0
  91. nautobot/project-static/docs/development/apps/api/views/index.html +14 -0
  92. nautobot/project-static/docs/development/apps/api/views/nautobot-generic-views.html +14 -0
  93. nautobot/project-static/docs/development/apps/api/views/nautobotuiviewset.html +14 -0
  94. nautobot/project-static/docs/development/apps/api/views/nautobotuiviewsetrouter.html +14 -0
  95. nautobot/project-static/docs/development/apps/api/views/notes.html +14 -0
  96. nautobot/project-static/docs/development/apps/api/views/rest-api.html +14 -0
  97. nautobot/project-static/docs/development/apps/api/views/urls.html +14 -0
  98. nautobot/project-static/docs/development/apps/index.html +14 -0
  99. nautobot/project-static/docs/development/apps/migration/code-updates.html +14 -0
  100. nautobot/project-static/docs/development/apps/migration/dependency-updates.html +14 -0
  101. nautobot/project-static/docs/development/apps/migration/from-v1.html +14 -0
  102. nautobot/project-static/docs/development/apps/migration/model-updates/dcim.html +14 -0
  103. nautobot/project-static/docs/development/apps/migration/model-updates/extras.html +14 -0
  104. nautobot/project-static/docs/development/apps/migration/model-updates/global.html +14 -0
  105. nautobot/project-static/docs/development/apps/migration/model-updates/ipam.html +14 -0
  106. nautobot/project-static/docs/development/apps/porting-from-netbox.html +14 -0
  107. nautobot/project-static/docs/development/core/application-registry.html +14 -0
  108. nautobot/project-static/docs/development/core/best-practices.html +14 -0
  109. nautobot/project-static/docs/development/core/bootstrap-ui.html +14 -0
  110. nautobot/project-static/docs/development/core/caching.html +14 -0
  111. nautobot/project-static/docs/development/core/docker-compose-advanced-use-cases.html +14 -0
  112. nautobot/project-static/docs/development/core/extending-models.html +14 -0
  113. nautobot/project-static/docs/development/core/generic-views.html +14 -0
  114. nautobot/project-static/docs/development/core/getting-started.html +33 -10
  115. nautobot/project-static/docs/development/core/homepage.html +14 -0
  116. nautobot/project-static/docs/development/core/index.html +14 -0
  117. nautobot/project-static/docs/development/core/model-features.html +14 -0
  118. nautobot/project-static/docs/development/core/natural-keys.html +14 -0
  119. nautobot/project-static/docs/development/core/navigation-menu.html +14 -0
  120. nautobot/project-static/docs/development/core/release-checklist.html +14 -0
  121. nautobot/project-static/docs/development/core/role-internals.html +14 -0
  122. nautobot/project-static/docs/development/core/style-guide.html +14 -0
  123. nautobot/project-static/docs/development/core/templates.html +14 -0
  124. nautobot/project-static/docs/development/core/testing.html +14 -0
  125. nautobot/project-static/docs/development/core/user-preferences.html +14 -0
  126. nautobot/project-static/docs/development/index.html +14 -0
  127. nautobot/project-static/docs/development/jobs/index.html +14 -0
  128. nautobot/project-static/docs/development/jobs/migration/from-v1.html +14 -0
  129. nautobot/project-static/docs/index.html +14 -0
  130. nautobot/project-static/docs/objects.inv +0 -0
  131. nautobot/project-static/docs/release-notes/index.html +14 -0
  132. nautobot/project-static/docs/release-notes/version-1.0.html +14 -0
  133. nautobot/project-static/docs/release-notes/version-1.1.html +14 -0
  134. nautobot/project-static/docs/release-notes/version-1.2.html +14 -0
  135. nautobot/project-static/docs/release-notes/version-1.3.html +14 -0
  136. nautobot/project-static/docs/release-notes/version-1.4.html +14 -0
  137. nautobot/project-static/docs/release-notes/version-1.5.html +14 -0
  138. nautobot/project-static/docs/release-notes/version-1.6.html +14 -0
  139. nautobot/project-static/docs/release-notes/version-2.0.html +14 -0
  140. nautobot/project-static/docs/release-notes/version-2.1.html +365 -159
  141. nautobot/project-static/docs/search/search_index.json +1 -1
  142. nautobot/project-static/docs/sitemap.xml +245 -240
  143. nautobot/project-static/docs/sitemap.xml.gz +0 -0
  144. nautobot/project-static/docs/user-guide/administration/configuration/authentication/ldap.html +14 -0
  145. nautobot/project-static/docs/user-guide/administration/configuration/authentication/remote.html +14 -0
  146. nautobot/project-static/docs/user-guide/administration/configuration/authentication/sso.html +14 -0
  147. nautobot/project-static/docs/user-guide/administration/configuration/index.html +14 -0
  148. nautobot/project-static/docs/user-guide/administration/configuration/optional-settings.html +14 -0
  149. nautobot/project-static/docs/user-guide/administration/configuration/required-settings.html +14 -0
  150. nautobot/project-static/docs/user-guide/administration/configuration/time-zones.html +14 -0
  151. nautobot/project-static/docs/user-guide/administration/guides/caching.html +14 -0
  152. nautobot/project-static/docs/user-guide/administration/guides/celery-queues.html +14 -0
  153. nautobot/project-static/docs/user-guide/administration/guides/healthcheck.html +14 -0
  154. nautobot/project-static/docs/user-guide/administration/guides/permissions.html +14 -0
  155. nautobot/project-static/docs/user-guide/administration/guides/prometheus-metrics.html +14 -0
  156. nautobot/project-static/docs/user-guide/administration/guides/replicating-nautobot.html +14 -0
  157. nautobot/project-static/docs/user-guide/administration/guides/request-profiling.html +14 -0
  158. nautobot/project-static/docs/user-guide/administration/guides/s3-django-storage.html +14 -0
  159. nautobot/project-static/docs/user-guide/administration/installation/app-install.html +14 -0
  160. nautobot/project-static/docs/user-guide/administration/installation/docker.html +21 -3
  161. nautobot/project-static/docs/user-guide/administration/installation/external-authentication.html +14 -0
  162. nautobot/project-static/docs/user-guide/administration/installation/health-checks.html +6019 -0
  163. nautobot/project-static/docs/user-guide/administration/installation/http-server.html +14 -0
  164. nautobot/project-static/docs/user-guide/administration/installation/index.html +14 -0
  165. nautobot/project-static/docs/user-guide/administration/installation/install_system.html +14 -0
  166. nautobot/project-static/docs/user-guide/administration/installation/nautobot.html +14 -0
  167. nautobot/project-static/docs/user-guide/administration/installation/selinux-troubleshooting.html +17 -3
  168. nautobot/project-static/docs/user-guide/administration/installation/services.html +14 -0
  169. nautobot/project-static/docs/user-guide/administration/migration/migrating-from-netbox.html +14 -0
  170. nautobot/project-static/docs/user-guide/administration/migration/migrating-from-postgresql.html +14 -0
  171. nautobot/project-static/docs/user-guide/administration/tools/nautobot-server.html +14 -0
  172. nautobot/project-static/docs/user-guide/administration/tools/nautobot-shell.html +14 -0
  173. nautobot/project-static/docs/user-guide/administration/upgrading/database-backup.html +14 -0
  174. nautobot/project-static/docs/user-guide/administration/upgrading/from-v1/ipam/after-you-upgrade.html +14 -0
  175. nautobot/project-static/docs/user-guide/administration/upgrading/from-v1/ipam/before-you-upgrade.html +14 -0
  176. nautobot/project-static/docs/user-guide/administration/upgrading/from-v1/ipam/for-developers.html +14 -0
  177. nautobot/project-static/docs/user-guide/administration/upgrading/from-v1/ipam/index.html +14 -0
  178. nautobot/project-static/docs/user-guide/administration/upgrading/from-v1/ipam/whats-changed.html +14 -0
  179. nautobot/project-static/docs/user-guide/administration/upgrading/from-v1/region-and-site-data-migration-guide.html +14 -0
  180. nautobot/project-static/docs/user-guide/administration/upgrading/from-v1/upgrading-from-nautobot-v1.html +14 -0
  181. nautobot/project-static/docs/user-guide/administration/upgrading/upgrading.html +14 -0
  182. nautobot/project-static/docs/user-guide/core-data-model/circuits/circuit.html +14 -0
  183. nautobot/project-static/docs/user-guide/core-data-model/circuits/circuittermination.html +14 -0
  184. nautobot/project-static/docs/user-guide/core-data-model/circuits/circuittype.html +14 -0
  185. nautobot/project-static/docs/user-guide/core-data-model/circuits/provider.html +14 -0
  186. nautobot/project-static/docs/user-guide/core-data-model/circuits/providernetwork.html +14 -0
  187. nautobot/project-static/docs/user-guide/core-data-model/dcim/cable.html +14 -0
  188. nautobot/project-static/docs/user-guide/core-data-model/dcim/consoleport.html +14 -0
  189. nautobot/project-static/docs/user-guide/core-data-model/dcim/consoleporttemplate.html +14 -0
  190. nautobot/project-static/docs/user-guide/core-data-model/dcim/consoleserverport.html +14 -0
  191. nautobot/project-static/docs/user-guide/core-data-model/dcim/consoleserverporttemplate.html +14 -0
  192. nautobot/project-static/docs/user-guide/core-data-model/dcim/device.html +14 -0
  193. nautobot/project-static/docs/user-guide/core-data-model/dcim/devicebay.html +14 -0
  194. nautobot/project-static/docs/user-guide/core-data-model/dcim/devicebaytemplate.html +14 -0
  195. nautobot/project-static/docs/user-guide/core-data-model/dcim/deviceredundancygroup.html +14 -0
  196. nautobot/project-static/docs/user-guide/core-data-model/dcim/devicetype.html +14 -0
  197. nautobot/project-static/docs/user-guide/core-data-model/dcim/frontport.html +14 -0
  198. nautobot/project-static/docs/user-guide/core-data-model/dcim/frontporttemplate.html +14 -0
  199. nautobot/project-static/docs/user-guide/core-data-model/dcim/interface.html +14 -0
  200. nautobot/project-static/docs/user-guide/core-data-model/dcim/interfaceredundancygroup.html +14 -0
  201. nautobot/project-static/docs/user-guide/core-data-model/dcim/interfacetemplate.html +14 -0
  202. nautobot/project-static/docs/user-guide/core-data-model/dcim/inventoryitem.html +14 -0
  203. nautobot/project-static/docs/user-guide/core-data-model/dcim/location.html +14 -0
  204. nautobot/project-static/docs/user-guide/core-data-model/dcim/locationtype.html +14 -0
  205. nautobot/project-static/docs/user-guide/core-data-model/dcim/manufacturer.html +14 -0
  206. nautobot/project-static/docs/user-guide/core-data-model/dcim/platform.html +14 -0
  207. nautobot/project-static/docs/user-guide/core-data-model/dcim/powerfeed.html +14 -0
  208. nautobot/project-static/docs/user-guide/core-data-model/dcim/poweroutlet.html +14 -0
  209. nautobot/project-static/docs/user-guide/core-data-model/dcim/poweroutlettemplate.html +14 -0
  210. nautobot/project-static/docs/user-guide/core-data-model/dcim/powerpanel.html +14 -0
  211. nautobot/project-static/docs/user-guide/core-data-model/dcim/powerport.html +14 -0
  212. nautobot/project-static/docs/user-guide/core-data-model/dcim/powerporttemplate.html +14 -0
  213. nautobot/project-static/docs/user-guide/core-data-model/dcim/rack.html +14 -0
  214. nautobot/project-static/docs/user-guide/core-data-model/dcim/rackgroup.html +14 -0
  215. nautobot/project-static/docs/user-guide/core-data-model/dcim/rackreservation.html +14 -0
  216. nautobot/project-static/docs/user-guide/core-data-model/dcim/rearport.html +14 -0
  217. nautobot/project-static/docs/user-guide/core-data-model/dcim/rearporttemplate.html +14 -0
  218. nautobot/project-static/docs/user-guide/core-data-model/dcim/virtualchassis.html +14 -0
  219. nautobot/project-static/docs/user-guide/core-data-model/extras/configcontext.html +14 -0
  220. nautobot/project-static/docs/user-guide/core-data-model/extras/configcontextschema.html +14 -0
  221. nautobot/project-static/docs/user-guide/core-data-model/ipam/ipaddress.html +14 -0
  222. nautobot/project-static/docs/user-guide/core-data-model/ipam/namespace.html +14 -0
  223. nautobot/project-static/docs/user-guide/core-data-model/ipam/prefix.html +14 -0
  224. nautobot/project-static/docs/user-guide/core-data-model/ipam/rir.html +14 -0
  225. nautobot/project-static/docs/user-guide/core-data-model/ipam/routetarget.html +14 -0
  226. nautobot/project-static/docs/user-guide/core-data-model/ipam/service.html +14 -0
  227. nautobot/project-static/docs/user-guide/core-data-model/ipam/vlan.html +14 -0
  228. nautobot/project-static/docs/user-guide/core-data-model/ipam/vlangroup.html +14 -0
  229. nautobot/project-static/docs/user-guide/core-data-model/ipam/vrf.html +14 -0
  230. nautobot/project-static/docs/user-guide/core-data-model/overview/introduction.html +14 -0
  231. nautobot/project-static/docs/user-guide/core-data-model/tenancy/tenant.html +14 -0
  232. nautobot/project-static/docs/user-guide/core-data-model/tenancy/tenantgroup.html +14 -0
  233. nautobot/project-static/docs/user-guide/core-data-model/virtualization/cluster.html +14 -0
  234. nautobot/project-static/docs/user-guide/core-data-model/virtualization/clustergroup.html +14 -0
  235. nautobot/project-static/docs/user-guide/core-data-model/virtualization/clustertype.html +14 -0
  236. nautobot/project-static/docs/user-guide/core-data-model/virtualization/virtualmachine.html +14 -0
  237. nautobot/project-static/docs/user-guide/core-data-model/virtualization/vminterface.html +14 -0
  238. nautobot/project-static/docs/user-guide/feature-guides/custom-fields.html +14 -0
  239. nautobot/project-static/docs/user-guide/feature-guides/getting-started/creating-devices.html +14 -0
  240. nautobot/project-static/docs/user-guide/feature-guides/getting-started/creating-location-types-and-locations.html +14 -0
  241. nautobot/project-static/docs/user-guide/feature-guides/getting-started/index.html +14 -0
  242. nautobot/project-static/docs/user-guide/feature-guides/getting-started/interfaces.html +14 -0
  243. nautobot/project-static/docs/user-guide/feature-guides/getting-started/ipam.html +14 -0
  244. nautobot/project-static/docs/user-guide/feature-guides/getting-started/platforms.html +14 -0
  245. nautobot/project-static/docs/user-guide/feature-guides/getting-started/search-bar.html +14 -0
  246. nautobot/project-static/docs/user-guide/feature-guides/getting-started/tenants.html +14 -0
  247. nautobot/project-static/docs/user-guide/feature-guides/getting-started/vlans-and-vlan-groups.html +14 -0
  248. nautobot/project-static/docs/user-guide/feature-guides/git-data-source.html +14 -0
  249. nautobot/project-static/docs/user-guide/feature-guides/graphql.html +14 -0
  250. nautobot/project-static/docs/user-guide/feature-guides/ip-address-merge-tool.html +14 -0
  251. nautobot/project-static/docs/user-guide/feature-guides/relationships.html +14 -0
  252. nautobot/project-static/docs/user-guide/index.html +14 -0
  253. nautobot/project-static/docs/user-guide/platform-functionality/change-logging.html +14 -0
  254. nautobot/project-static/docs/user-guide/platform-functionality/computedfield.html +14 -0
  255. nautobot/project-static/docs/user-guide/platform-functionality/customfield.html +14 -0
  256. nautobot/project-static/docs/user-guide/platform-functionality/customlink.html +14 -0
  257. nautobot/project-static/docs/user-guide/platform-functionality/dynamicgroup.html +14 -0
  258. nautobot/project-static/docs/user-guide/platform-functionality/exporttemplate.html +14 -0
  259. nautobot/project-static/docs/user-guide/platform-functionality/externalintegration.html +14 -0
  260. nautobot/project-static/docs/user-guide/platform-functionality/gitrepository.html +14 -0
  261. nautobot/project-static/docs/user-guide/platform-functionality/graphql.html +14 -0
  262. nautobot/project-static/docs/user-guide/platform-functionality/graphqlquery.html +14 -0
  263. nautobot/project-static/docs/user-guide/platform-functionality/imageattachment.html +14 -0
  264. nautobot/project-static/docs/user-guide/platform-functionality/jobs/index.html +14 -0
  265. nautobot/project-static/docs/user-guide/platform-functionality/jobs/job-scheduling-and-approvals.html +14 -0
  266. nautobot/project-static/docs/user-guide/platform-functionality/jobs/jobbutton.html +14 -0
  267. nautobot/project-static/docs/user-guide/platform-functionality/jobs/jobhook.html +14 -0
  268. nautobot/project-static/docs/user-guide/platform-functionality/jobs/models.html +14 -0
  269. nautobot/project-static/docs/user-guide/platform-functionality/napalm.html +14 -0
  270. nautobot/project-static/docs/user-guide/platform-functionality/note.html +14 -0
  271. nautobot/project-static/docs/user-guide/platform-functionality/relationship.html +14 -0
  272. nautobot/project-static/docs/user-guide/platform-functionality/rest-api/authentication.html +14 -0
  273. nautobot/project-static/docs/user-guide/platform-functionality/rest-api/filtering.html +14 -0
  274. nautobot/project-static/docs/user-guide/platform-functionality/rest-api/overview.html +14 -0
  275. nautobot/project-static/docs/user-guide/platform-functionality/rest-api/ui-related-endpoints.html +14 -0
  276. nautobot/project-static/docs/user-guide/platform-functionality/role.html +14 -0
  277. nautobot/project-static/docs/user-guide/platform-functionality/secret.html +14 -0
  278. nautobot/project-static/docs/user-guide/platform-functionality/status.html +14 -0
  279. nautobot/project-static/docs/user-guide/platform-functionality/tag.html +14 -0
  280. nautobot/project-static/docs/user-guide/platform-functionality/template-filters.html +14 -0
  281. nautobot/project-static/docs/user-guide/platform-functionality/users/objectpermission.html +14 -0
  282. nautobot/project-static/docs/user-guide/platform-functionality/users/token.html +14 -0
  283. nautobot/project-static/docs/user-guide/platform-functionality/webhook.html +14 -0
  284. nautobot/tenancy/api/urls.py +1 -2
  285. nautobot/tenancy/api/views.py +0 -12
  286. nautobot/users/api/urls.py +1 -2
  287. nautobot/users/api/views.py +2 -65
  288. nautobot/users/views.py +8 -8
  289. nautobot/virtualization/api/urls.py +1 -2
  290. nautobot/virtualization/api/views.py +0 -12
  291. {nautobot-2.1.8.dist-info → nautobot-2.1.9.dist-info}/METADATA +2 -2
  292. {nautobot-2.1.8.dist-info → nautobot-2.1.9.dist-info}/RECORD +296 -294
  293. {nautobot-2.1.8.dist-info → nautobot-2.1.9.dist-info}/LICENSE.txt +0 -0
  294. {nautobot-2.1.8.dist-info → nautobot-2.1.9.dist-info}/NOTICE +0 -0
  295. {nautobot-2.1.8.dist-info → nautobot-2.1.9.dist-info}/WHEEL +0 -0
  296. {nautobot-2.1.8.dist-info → nautobot-2.1.9.dist-info}/entry_points.txt +0 -0
@@ -21,6 +21,7 @@ from nautobot.dcim.tests import test_views
21
21
  from nautobot.extras.choices import (
22
22
  CustomFieldTypeChoices,
23
23
  JobExecutionType,
24
+ LogLevelChoices,
24
25
  ObjectChangeActionChoices,
25
26
  SecretsGroupAccessTypeChoices,
26
27
  SecretsGroupSecretTypeChoices,
@@ -40,6 +41,7 @@ from nautobot.extras.models import (
40
41
  GraphQLQuery,
41
42
  Job,
42
43
  JobButton,
44
+ JobLogEntry,
43
45
  JobResult,
44
46
  Note,
45
47
  ObjectChange,
@@ -617,6 +619,49 @@ class DynamicGroupTestCase(
617
619
  "dynamic_group_memberships-MAX_NUM_FORMS": "1000",
618
620
  }
619
621
 
622
+ def test_get_object_dynamic_groups_anonymous(self):
623
+ url = reverse("dcim:device_dynamicgroups", kwargs={"pk": Device.objects.first().pk})
624
+ self.client.logout()
625
+ response = self.client.get(url, follow=True)
626
+ self.assertHttpStatus(response, 200)
627
+ self.assertRedirects(response, f"/login/?next={url}")
628
+
629
+ def test_get_object_dynamic_groups_without_permission(self):
630
+ url = reverse("dcim:device_dynamicgroups", kwargs={"pk": Device.objects.first().pk})
631
+ response = self.client.get(url)
632
+ self.assertHttpStatus(response, [403, 404])
633
+
634
+ def test_get_object_dynamic_groups_with_permission(self):
635
+ url = reverse("dcim:device_dynamicgroups", kwargs={"pk": Device.objects.first().pk})
636
+ self.add_permissions("dcim.view_device", "extras.view_dynamicgroup")
637
+ response = self.client.get(url)
638
+ self.assertHttpStatus(response, 200)
639
+ response_body = response.content.decode(response.charset)
640
+ self.assertIn("DG 1", response_body, msg=response_body)
641
+ self.assertIn("DG 2", response_body, msg=response_body)
642
+ self.assertIn("DG 3", response_body, msg=response_body)
643
+
644
+ def test_get_object_dynamic_groups_with_constrained_permission(self):
645
+ self.add_permissions("extras.view_dynamicgroup")
646
+ obj_perm = ObjectPermission(
647
+ name="View a device",
648
+ constraints={"pk": Device.objects.first().pk},
649
+ actions=["view"],
650
+ )
651
+ obj_perm.save()
652
+ obj_perm.users.add(self.user)
653
+ obj_perm.object_types.add(ContentType.objects.get_for_model(Device))
654
+
655
+ url = reverse("dcim:device_dynamicgroups", kwargs={"pk": Device.objects.first().pk})
656
+ response = self.client.get(url)
657
+ self.assertHttpStatus(response, 200)
658
+ response_body = response.content.decode(response.charset)
659
+ self.assertIn("DG 1", response_body, msg=response_body)
660
+
661
+ url = reverse("dcim:device_dynamicgroups", kwargs={"pk": Device.objects.last().pk})
662
+ response = self.client.get(url)
663
+ self.assertHttpStatus(response, 404)
664
+
620
665
  @override_settings(EXEMPT_VIEW_PERMISSIONS=["*"])
621
666
  def test_edit_saved_filter(self):
622
667
  """Test that editing a filter works using the edit view."""
@@ -786,6 +831,34 @@ class GitRepositoryTestCase(
786
831
  self.form_data = form_data
787
832
  super().test_edit_object_with_constrained_permission()
788
833
 
834
+ def test_post_sync_repo_anonymous(self):
835
+ self.client.logout()
836
+ url = reverse("extras:gitrepository_sync", kwargs={"pk": self._get_queryset().first().pk})
837
+ response = self.client.post(url, follow=True)
838
+ self.assertHttpStatus(response, 200)
839
+ self.assertRedirects(response, f"/login/?next={url}")
840
+
841
+ def test_post_sync_repo_without_permission(self):
842
+ url = reverse("extras:gitrepository_sync", kwargs={"pk": self._get_queryset().first().pk})
843
+ response = self.client.post(url)
844
+ self.assertHttpStatus(response, [403, 404])
845
+
846
+ # TODO: mock/stub out `enqueue_pull_git_repository_and_refresh_data` and test successful POST with permissions
847
+
848
+ def test_post_dryrun_repo_anonymous(self):
849
+ self.client.logout()
850
+ url = reverse("extras:gitrepository_dryrun", kwargs={"pk": self._get_queryset().first().pk})
851
+ response = self.client.post(url, follow=True)
852
+ self.assertHttpStatus(response, 200)
853
+ self.assertRedirects(response, f"/login/?next={url}")
854
+
855
+ def test_post_dryrun_repo_without_permission(self):
856
+ url = reverse("extras:gitrepository_dryrun", kwargs={"pk": self._get_queryset().first().pk})
857
+ response = self.client.post(url)
858
+ self.assertHttpStatus(response, [403, 404])
859
+
860
+ # TODO: mock/stub out `enqueue_git_repository_diff_origin_and_local` and test successful POST with permissions
861
+
789
862
 
790
863
  class NoteTestCase(
791
864
  ViewTestCases.CreateObjectViewTestCase,
@@ -1503,6 +1576,34 @@ class JobResultTestCase(
1503
1576
  def setUpTestData(cls):
1504
1577
  JobResult.objects.create(name="pass.TestPass")
1505
1578
  JobResult.objects.create(name="fail.TestFail")
1579
+ JobLogEntry.objects.create(
1580
+ log_level=LogLevelChoices.LOG_INFO,
1581
+ job_result=JobResult.objects.first(),
1582
+ grouping="run",
1583
+ message="This is a test",
1584
+ )
1585
+
1586
+ def test_get_joblogentrytable_anonymous(self):
1587
+ url = reverse("extras:jobresult_log-table", kwargs={"pk": JobResult.objects.first().pk})
1588
+ self.client.logout()
1589
+ response = self.client.get(url, follow=True)
1590
+ self.assertHttpStatus(response, 200)
1591
+ self.assertRedirects(response, f"/login/?next={url}")
1592
+
1593
+ def test_get_joblogentrytable_without_permission(self):
1594
+ url = reverse("extras:jobresult_log-table", kwargs={"pk": JobResult.objects.first().pk})
1595
+ response = self.client.get(url)
1596
+ self.assertHttpStatus(response, [403, 404])
1597
+
1598
+ def test_get_joblogentrytable_with_permission(self):
1599
+ url = reverse("extras:jobresult_log-table", kwargs={"pk": JobResult.objects.first().pk})
1600
+ self.add_permissions("extras.view_jobresult", "extras.view_joblogentry")
1601
+ response = self.client.get(url)
1602
+ self.assertHttpStatus(response, 200)
1603
+ response_body = response.content.decode(response.charset)
1604
+ self.assertIn("This is a test", response_body)
1605
+
1606
+ # TODO test with constrained permissions on both JobResult and JobLogEntry records
1506
1607
 
1507
1608
 
1508
1609
  class JobTestCase(
nautobot/extras/views.py CHANGED
@@ -713,7 +713,7 @@ class DynamicGroupBulkDeleteView(generic.BulkDeleteView):
713
713
  filterset = filters.DynamicGroupFilterSet
714
714
 
715
715
 
716
- class ObjectDynamicGroupsView(View):
716
+ class ObjectDynamicGroupsView(generic.GenericView):
717
717
  """
718
718
  Present a list of dynamic groups associated to a particular object.
719
719
  base_template: The name of the template to extend. If not provided, "<app>/<model>.html" will be used.
@@ -912,18 +912,18 @@ def check_and_call_git_repository_function(request, pk, func):
912
912
  messages.error(request, "Unable to run job: Celery worker process not running.")
913
913
  return redirect(request.get_full_path(), permanent=False)
914
914
  else:
915
- repository = get_object_or_404(GitRepository, pk=pk)
915
+ repository = get_object_or_404(GitRepository.objects.restrict(request.user, "change"), pk=pk)
916
916
  job_result = func(repository, request.user)
917
917
 
918
918
  return redirect(job_result.get_absolute_url())
919
919
 
920
920
 
921
- class GitRepositorySyncView(View):
921
+ class GitRepositorySyncView(generic.GenericView):
922
922
  def post(self, request, pk):
923
923
  return check_and_call_git_repository_function(request, pk, enqueue_pull_git_repository_and_refresh_data)
924
924
 
925
925
 
926
- class GitRepositoryDryRunView(View):
926
+ class GitRepositoryDryRunView(generic.GenericView):
927
927
  def post(self, request, pk):
928
928
  return check_and_call_git_repository_function(request, pk, enqueue_git_repository_diff_origin_and_local)
929
929
 
@@ -1559,7 +1559,7 @@ class JobResultView(generic.ObjectView):
1559
1559
  }
1560
1560
 
1561
1561
 
1562
- class JobLogEntryTableView(View):
1562
+ class JobLogEntryTableView(generic.GenericView):
1563
1563
  """
1564
1564
  Display a table of `JobLogEntry` objects for a given `JobResult` instance.
1565
1565
  """
@@ -1567,7 +1567,7 @@ class JobLogEntryTableView(View):
1567
1567
  queryset = JobResult.objects.all()
1568
1568
 
1569
1569
  def get(self, request, pk=None):
1570
- instance = self.queryset.get(pk=pk)
1570
+ instance = get_object_or_404(self.queryset.restrict(request.user, "view"), pk=pk)
1571
1571
  filter_q = request.GET.get("q")
1572
1572
  if filter_q:
1573
1573
  queryset = instance.job_log_entries.filter(
@@ -1646,7 +1646,7 @@ class ObjectChangeView(generic.ObjectView):
1646
1646
  }
1647
1647
 
1648
1648
 
1649
- class ObjectChangeLogView(View):
1649
+ class ObjectChangeLogView(generic.GenericView):
1650
1650
  """
1651
1651
  Present a history of changes made to a particular object.
1652
1652
  base_template: The name of the template to extend. If not provided, "<app>/<model>.html" will be used.
@@ -1730,7 +1730,7 @@ class NoteDeleteView(generic.ObjectDeleteView):
1730
1730
  queryset = Note.objects.all()
1731
1731
 
1732
1732
 
1733
- class ObjectNotesView(View):
1733
+ class ObjectNotesView(generic.GenericView):
1734
1734
  """
1735
1735
  Present a list of notes associated to a particular object.
1736
1736
  base_template: The name of the template to extend. If not provided, "<app>/<model>.html" will be used.
@@ -1751,7 +1751,7 @@ class ObjectNotesView(View):
1751
1751
  "assigned_object_id": obj.pk,
1752
1752
  }
1753
1753
  )
1754
- notes_table = tables.NoteTable(obj.notes)
1754
+ notes_table = tables.NoteTable(obj.notes.restrict(request.user, "view"))
1755
1755
 
1756
1756
  # Apply the request context
1757
1757
  paginate = {
@@ -1972,7 +1972,7 @@ class SecretView(generic.ObjectView):
1972
1972
  }
1973
1973
 
1974
1974
 
1975
- class SecretProviderParametersFormView(View):
1975
+ class SecretProviderParametersFormView(generic.GenericView):
1976
1976
  """
1977
1977
  Helper view to SecretView; retrieve the HTML form appropriate for entering parameters for a given SecretsProvider.
1978
1978
  """
nautobot/ipam/api/urls.py CHANGED
@@ -2,8 +2,7 @@ from nautobot.core.api.routers import OrderedDefaultRouter
2
2
 
3
3
  from . import views
4
4
 
5
- router = OrderedDefaultRouter()
6
- router.APIRootView = views.IPAMRootView
5
+ router = OrderedDefaultRouter(view_name="IPAM")
7
6
 
8
7
  # Namespaces
9
8
  router.register("namespaces", views.NamespaceViewSet)
@@ -5,7 +5,6 @@ from drf_spectacular.utils import extend_schema
5
5
  from rest_framework import status
6
6
  from rest_framework.decorators import action
7
7
  from rest_framework.response import Response
8
- from rest_framework.routers import APIRootView
9
8
 
10
9
  from nautobot.core.models.querysets import count_related
11
10
  from nautobot.core.utils.config import get_settings_or_config
@@ -26,16 +25,6 @@ from nautobot.ipam.models import (
26
25
 
27
26
  from . import serializers
28
27
 
29
-
30
- class IPAMRootView(APIRootView):
31
- """
32
- IPAM API root view
33
- """
34
-
35
- def get_view_name(self):
36
- return "IPAM"
37
-
38
-
39
28
  #
40
29
  # Namespace
41
30
  #
nautobot/ipam/tables.py CHANGED
@@ -179,7 +179,6 @@ VLAN_LINK = """
179
179
  {% url 'ipam:vlan_add' %}\
180
180
  ?vid={{ record.vid }}&vlan_group={{ vlan_group.pk }}\
181
181
  {% if vlan_group.location %}&location={{ vlan_group.location.pk }}{% endif %}\
182
- {% if vlan_group.location %}&location={{ vlan_group.location.pk }}{% endif %}\
183
182
  " class="btn btn-xs btn-success">{{ record.available }} VLAN{{ record.available|pluralize }} available</a>\
184
183
  {% else %}
185
184
  {{ record.available }} VLAN{{ record.available|pluralize }} available
@@ -1,4 +1,3 @@
1
- from django.test import override_settings
2
1
  from django.urls import reverse
3
2
  from rest_framework import status
4
3
 
@@ -9,8 +8,8 @@ class TestPrefix(APITestCase):
9
8
  def setUp(self):
10
9
  super().setUp()
11
10
  self.api_url = reverse("graphql-api")
11
+ self.add_permissions("ipam.view_prefix")
12
12
 
13
- @override_settings(EXEMPT_VIEW_PERMISSIONS=["*"])
14
13
  def test_prefix_ip_version(self):
15
14
  """Test ip_version is available for a Prefix via GraphQL."""
16
15
  get_prefixes_query = """
@@ -23,7 +22,7 @@ class TestPrefix(APITestCase):
23
22
  }
24
23
  """
25
24
  payload = {"query": get_prefixes_query}
26
- response = self.client.post(self.api_url, payload, format="json")
25
+ response = self.client.post(self.api_url, payload, format="json", **self.header)
27
26
  self.assertEqual(response.status_code, status.HTTP_200_OK)
28
27
  prefixes = response.data["data"]["prefixes"]
29
28
  self.assertIsInstance(prefixes, list)
nautobot/ipam/views.py CHANGED
@@ -775,7 +775,7 @@ class IPAddressEditView(generic.ObjectEditView):
775
775
  _, error_msg = retrieve_interface_or_vminterface_from_request(request)
776
776
  if error_msg:
777
777
  messages.warning(request, error_msg)
778
- return redirect(self.get_return_url(request), default_return_url="ipam:ipaddress_add")
778
+ return redirect(self.get_return_url(request, default_return_url="ipam:ipaddress_add"))
779
779
 
780
780
  return super().dispatch(request, *args, **kwargs)
781
781
 
@@ -858,17 +858,17 @@ class IPAddressAssignView(view_mixins.GetReturnURLMixin, generic.ObjectView):
858
858
  """
859
859
 
860
860
  queryset = IPAddress.objects.all()
861
- default_return_url = "ipam:ipaddress_add"
862
861
 
863
862
  def dispatch(self, request, *args, **kwargs):
864
- # Redirect user if an interface has not been provided
865
- if "interface" not in request.GET and "vminterface" not in request.GET:
866
- return redirect(self.get_return_url(request))
863
+ if request.user.is_authenticated:
864
+ # Redirect user if an interface has not been provided
865
+ if "interface" not in request.GET and "vminterface" not in request.GET:
866
+ return redirect(self.get_return_url(request, default_return_url="ipam:ipaddress_add"))
867
867
 
868
- _, error_msg = retrieve_interface_or_vminterface_from_request(request)
869
- if error_msg:
870
- messages.warning(request, error_msg)
871
- return redirect(self.get_return_url(request))
868
+ _, error_msg = retrieve_interface_or_vminterface_from_request(request)
869
+ if error_msg:
870
+ messages.warning(request, error_msg)
871
+ return redirect(self.get_return_url(request, default_return_url="ipam:ipaddress_add"))
872
872
 
873
873
  return super().dispatch(request, *args, **kwargs)
874
874
 
@@ -27,6 +27,7 @@ body {
27
27
  transition-duration: var(--navbar-transition-duration);
28
28
  transition-timing-function: ease-in-out;
29
29
  transition-property: margin-left, width;
30
+ min-height: calc(100vh - 20px);
30
31
  }
31
32
  #main-content > .form {
32
33
  margin-top: 20px;
@@ -537,6 +537,20 @@
537
537
 
538
538
 
539
539
 
540
+ <li class="md-nav__item">
541
+ <a href="/projects/core/en/stable/user-guide/administration/installation/health-checks.html" class="md-nav__link">
542
+ Health Checks
543
+ </a>
544
+ </li>
545
+
546
+
547
+
548
+
549
+
550
+
551
+
552
+
553
+
540
554
  <li class="md-nav__item">
541
555
  <a href="/projects/core/en/stable/user-guide/administration/installation/selinux-troubleshooting.html" class="md-nav__link">
542
556
  SELinux Troubleshooting
@@ -550,6 +550,20 @@
550
550
 
551
551
 
552
552
 
553
+ <li class="md-nav__item">
554
+ <a href="../user-guide/administration/installation/health-checks.html" class="md-nav__link">
555
+ Health Checks
556
+ </a>
557
+ </li>
558
+
559
+
560
+
561
+
562
+
563
+
564
+
565
+
566
+
553
567
  <li class="md-nav__item">
554
568
  <a href="../user-guide/administration/installation/selinux-troubleshooting.html" class="md-nav__link">
555
569
  SELinux Troubleshooting
@@ -548,6 +548,20 @@
548
548
 
549
549
 
550
550
 
551
+ <li class="md-nav__item">
552
+ <a href="../user-guide/administration/installation/health-checks.html" class="md-nav__link">
553
+ Health Checks
554
+ </a>
555
+ </li>
556
+
557
+
558
+
559
+
560
+
561
+
562
+
563
+
564
+
551
565
  <li class="md-nav__item">
552
566
  <a href="../user-guide/administration/installation/selinux-troubleshooting.html" class="md-nav__link">
553
567
  SELinux Troubleshooting
@@ -550,6 +550,20 @@
550
550
 
551
551
 
552
552
 
553
+ <li class="md-nav__item">
554
+ <a href="../../../user-guide/administration/installation/health-checks.html" class="md-nav__link">
555
+ Health Checks
556
+ </a>
557
+ </li>
558
+
559
+
560
+
561
+
562
+
563
+
564
+
565
+
566
+
553
567
  <li class="md-nav__item">
554
568
  <a href="../../../user-guide/administration/installation/selinux-troubleshooting.html" class="md-nav__link">
555
569
  SELinux Troubleshooting
@@ -550,6 +550,20 @@
550
550
 
551
551
 
552
552
 
553
+ <li class="md-nav__item">
554
+ <a href="../../../user-guide/administration/installation/health-checks.html" class="md-nav__link">
555
+ Health Checks
556
+ </a>
557
+ </li>
558
+
559
+
560
+
561
+
562
+
563
+
564
+
565
+
566
+
553
567
  <li class="md-nav__item">
554
568
  <a href="../../../user-guide/administration/installation/selinux-troubleshooting.html" class="md-nav__link">
555
569
  SELinux Troubleshooting