From fb23b750b7495f00a4f6192d9f1ff18805ab9446 Mon Sep 17 00:00:00 2001 From: Daniel Sheppard Date: Tue, 23 May 2023 15:17:02 -0500 Subject: [PATCH 1/3] Update GH Workflow --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 90eac0e..2f3bf15 100644 --- a/setup.py +++ b/setup.py @@ -2,7 +2,7 @@ setup( name='netbox_config_backup', - version='1.4.5', + version='1.4.6', description='NetBox Configuration Backup', long_description='Plugin to backup device configuration', url='https://github.com/dansheps/netbox-config-backup/', From db83b8688b34ab2cf081cce5f464f4a0ff21c8e7 Mon Sep 17 00:00:00 2001 From: Daniel Sheppard Date: Tue, 23 May 2023 15:18:01 -0500 Subject: [PATCH 2/3] Update GH Workflow --- .github/workflows/pypi.yml | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a/.github/workflows/pypi.yml b/.github/workflows/pypi.yml index 5d6c7ec..cd1e512 100644 --- a/.github/workflows/pypi.yml +++ b/.github/workflows/pypi.yml @@ -2,43 +2,35 @@ name: PyPI Build on: release: types: released - jobs: - build: + pypi-publish: + name: Upload Release to PyPI runs-on: ubuntu-latest + permissions: + id-token: write strategy: matrix: python-version: [3.9] steps: - - name: Checkout repo uses: actions/checkout@v2 - - name: Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v2 with: python-version: ${{ matrix.python-version }} - - name: Install dependencies run: | python -m pip install --upgrade pip pip install --upgrade setuptools wheel - - - name: Build run: python setup.py sdist bdist_wheel - - name: Publish package to TestPyPI uses: pypa/gh-action-pypi-publish@release/v1 with: - user: __token__ - password: ${{ secrets.TEST_PYPI_API_TOKEN }} repository_url: https://test.pypi.org/legacy/ skip_existing: true - name: Publish package uses: pypa/gh-action-pypi-publish@release/v1 with: - user: __token__ - password: ${{ secrets.PYPI_API_TOKEN }} skip_existing: true \ No newline at end of file From e852ca5978b7490216f1ca13f431d2637072b107 Mon Sep 17 00:00:00 2001 From: Daniel Sheppard Date: Wed, 21 Jun 2023 08:38:53 -0500 Subject: [PATCH 3/3] Fixes #69 - Fix errant API serializer hyperlinks --- netbox_config_backup/api/nested_serializers.py | 2 +- netbox_config_backup/api/serializers.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/netbox_config_backup/api/nested_serializers.py b/netbox_config_backup/api/nested_serializers.py index 87ac5e4..047e649 100644 --- a/netbox_config_backup/api/nested_serializers.py +++ b/netbox_config_backup/api/nested_serializers.py @@ -10,7 +10,7 @@ class NestedBackupSerializer(WritableNestedSerializer): - url = serializers.HyperlinkedIdentityField(view_name='plugins-api:netbox_sync-api:sync-detail') + url = serializers.HyperlinkedIdentityField(view_name='plugins-api:netbox_config_backup-api:sync-detail') class Meta: model = Backup diff --git a/netbox_config_backup/api/serializers.py b/netbox_config_backup/api/serializers.py index 72d8286..05c1665 100644 --- a/netbox_config_backup/api/serializers.py +++ b/netbox_config_backup/api/serializers.py @@ -13,7 +13,7 @@ class BackupSerializer(NetBoxModelSerializer): - url = serializers.HyperlinkedIdentityField(view_name='plugins-api:netbox_sync-api:sync-detail') + url = serializers.HyperlinkedIdentityField(view_name='plugins-api:netbox_config_backup-api:sync-detail') device = NestedDeviceSerializer() ip = NestedIPAddressSerializer()