Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: remove ingestion logs view #58

Merged
merged 4 commits into from
Feb 6, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -1 +1 @@
* @leoparente @mfiedorowicz
* @leoparente @ltucker @mfiedorowicz
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,5 @@ docker-compose-netbox-plugin-test:

.PHONY: docker-compose-netbox-plugin-test-cover
docker-compose-netbox-plugin-test-cover:
-@$(DOCKER_COMPOSE) -f docker/docker-compose.yaml -f docker/docker-compose.test.yaml run --rm -u root -e COVERAGE_FILE=/opt/netbox/netbox/coverage/.coverage netbox sh -c "coverage run --source=netbox_diode_plugin --omit=*_pb2*,*/migrations/* ./manage.py test --keepdb netbox_diode_plugin && coverage xml -o /opt/netbox/netbox/coverage/report.xml && coverage report -m | tee /opt/netbox/netbox/coverage/report.txt"
-@$(DOCKER_COMPOSE) -f docker/docker-compose.yaml -f docker/docker-compose.test.yaml run --rm -u root -e COVERAGE_FILE=/opt/netbox/netbox/coverage/.coverage netbox sh -c "coverage run --source=netbox_diode_plugin --omit=*/migrations/* ./manage.py test --keepdb netbox_diode_plugin && coverage xml -o /opt/netbox/netbox/coverage/report.xml && coverage report -m | tee /opt/netbox/netbox/coverage/report.txt"
@$(MAKE) docker-compose-netbox-plugin-down
2 changes: 1 addition & 1 deletion docker/Dockerfile-diode-netbox-plugin
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM netboxcommunity/netbox:v4.1-3.0.1
FROM netboxcommunity/netbox:v4.1.11-3.0.2

COPY ./netbox/configuration/ /etc/netbox/config/
RUN chmod 755 /etc/netbox/config/* && \
Expand Down
2 changes: 1 addition & 1 deletion docker/docker-compose.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: diode-netbox-plugin
services:
netbox: &netbox
image: netboxcommunity/netbox:v4.1-3.0.1-diode-netbox-plugin
image: netboxcommunity/netbox:v4.1.11-3.0.2-diode-netbox-plugin
build:
context: .
dockerfile: Dockerfile-diode-netbox-plugin
Expand Down
8 changes: 5 additions & 3 deletions netbox_diode_plugin/models.py
Original file line number Diff line number Diff line change
@@ -1,19 +1,21 @@
# !/usr/bin/env python
# Copyright 2024 NetBox Labs Inc
"""Diode NetBox Plugin - Models."""
from urllib.parse import urlparse

from django.core.exceptions import ValidationError
from django.db import models
from django.urls import reverse
from netbox.models import NetBoxModel

from netbox_diode_plugin.reconciler.sdk.client import parse_target


def diode_target_validator(target):
"""Diode target validator."""
try:
_, _, _ = parse_target(target)
parsed_target = urlparse(target)

if parsed_target.scheme not in ["grpc", "grpcs"]:
raise ValueError("target should start with grpc:// or grpcs://")
except ValueError as exc:
raise ValidationError(exc)

Expand Down
7 changes: 0 additions & 7 deletions netbox_diode_plugin/navigation.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,6 @@

from netbox.plugins import PluginMenu, PluginMenuItem

ingestion_logs = {
"link": "plugins:netbox_diode_plugin:ingestion_logs",
"link_text": "Ingestion Logs",
"staff_only": True,
}

settings = {
"link": "plugins:netbox_diode_plugin:settings",
"link_text": "Settings",
Expand All @@ -23,7 +17,6 @@
(
"Diode",
(
PluginMenuItem(**ingestion_logs),
PluginMenuItem(**settings),
),
),
Expand Down
3 changes: 0 additions & 3 deletions netbox_diode_plugin/reconciler/__init__.py

This file was deleted.

3 changes: 0 additions & 3 deletions netbox_diode_plugin/reconciler/sdk/__init__.py

This file was deleted.

256 changes: 0 additions & 256 deletions netbox_diode_plugin/reconciler/sdk/client.py

This file was deleted.

33 changes: 0 additions & 33 deletions netbox_diode_plugin/reconciler/sdk/exceptions.py

This file was deleted.

3 changes: 0 additions & 3 deletions netbox_diode_plugin/reconciler/sdk/v1/__init__.py

This file was deleted.

217 changes: 0 additions & 217 deletions netbox_diode_plugin/reconciler/sdk/v1/ingester_pb2.py

This file was deleted.

Loading