From 482537c72f01a2bfa6c73ea071b333d7e2023cf9 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Mon, 22 Jun 2026 03:49:34 -0400 Subject: [PATCH] Closes #22393: Drop support for Redis 5.x (#22471) --- docs/installation/2-redis.md | 3 --- docs/installation/index.md | 2 +- docs/installation/upgrading.md | 2 +- netbox/core/checks.py | 17 ++++++++--------- 4 files changed, 10 insertions(+), 14 deletions(-) diff --git a/docs/installation/2-redis.md b/docs/installation/2-redis.md index f412cced1..fda3fb880 100644 --- a/docs/installation/2-redis.md +++ b/docs/installation/2-redis.md @@ -10,9 +10,6 @@ sudo apt install -y redis-server Before continuing, verify that your installed version of Redis is at least v6.0: -!!! warning "Redis v5.x is deprecated" - Support for Redis versions older than 6.0 is deprecated and will be removed in NetBox v4.7. - ```no-highlight redis-server -v ``` diff --git a/docs/installation/index.md b/docs/installation/index.md index 154b88aa3..bdb8dc33e 100644 --- a/docs/installation/index.md +++ b/docs/installation/index.md @@ -29,7 +29,7 @@ The following sections detail how to set up a new instance of NetBox: |------------|--------------------| | Python | 3.12, 3.13, 3.14 | | PostgreSQL | 15+ | -| Redis | 4.0+ | +| Redis | 6.0+ | Below is a simplified overview of the NetBox application stack for reference: diff --git a/docs/installation/upgrading.md b/docs/installation/upgrading.md index acb15725b..79593cfcc 100644 --- a/docs/installation/upgrading.md +++ b/docs/installation/upgrading.md @@ -34,7 +34,7 @@ NetBox requires the following dependencies: |------------|--------------------| | Python | 3.12, 3.13, 3.14 | | PostgreSQL | 15+ | -| Redis | 4.0+ | +| Redis | 6.0+ | ### Version History diff --git a/netbox/core/checks.py b/netbox/core/checks.py index d452641c7..5ddaa9325 100644 --- a/netbox/core/checks.py +++ b/netbox/core/checks.py @@ -74,22 +74,21 @@ def check_postgresql_version(app_configs, **kwargs): @register(Tags.caches) def check_redis_version(app_configs, **kwargs): """ - Warn if the Redis version is less than 6.0, as support for Redis older than 6.0 - will be removed in NetBox v4.7. + Report an error if the Redis version is less than 6.0. """ - warnings = [] + errors = [] try: client = cache.client.get_client() redis_version = tuple(int(x) for x in client.info()['redis_version'].split('.')) if redis_version < (6, 0): - warnings.append( - Warning( - f'Support for Redis {".".join(str(x) for x in redis_version)} is deprecated and will be ' - f'removed in NetBox v4.7.', + errors.append( + Error( + f'Redis {".".join(str(x) for x in redis_version)} is not supported. NetBox requires Redis 6.0 ' + f'or later.', hint='Please upgrade to Redis 6.0 or later.', - id='netbox.W002', + id='netbox.E002', ) ) except Exception: pass - return warnings + return errors