Skip to content

Introduction

Cookiecutter NetBox Plugin

Cookiecutter template for a NetBox plugin, built with popular develop tools and conform to best practice.

Note: Plugins from this version target NetBox 4.5+

Quickstart

Install the latest Cookiecutter if you haven't installed it yet (this requires Cookiecutter 2.6.0 or higher):

1
pip install -U cookiecutter

Generate a Python package project:

1
cookiecutter https://github.com/netbox-community/cookiecutter-netbox-plugin.git

Then follow the Quickstart Guide to finish other configurations.

Features

This tool will create Python project with the following features:

  • Mkdocs: Writing your docs in markdown style
  • Lint and format with Ruff: Fast Python linter and formatter
  • Pre-commit hooks: Automatic code quality checks on commit
  • Mkdocstrings: Auto API doc generation
  • Continuous Integration/Deployment by GitHub actions, includes:
    • Automated testing on every push
    • Publish documentation automatically
    • PyPI publishing with trusted publishers
  • Host your documentation from GitHub Pages with zero-config