Closes #11787: Rebuild any missing search cache entires after upgrade

This commit is contained in:
jeremystretch
2023-02-20 09:39:33 -05:00
parent 043bc880cc
commit de8029d9d1
4 changed files with 42 additions and 10 deletions

View File

@@ -103,6 +103,11 @@ COMMAND="python3 netbox/manage.py remove_stale_contenttypes --no-input"
echo "Removing stale content types ($COMMAND)..."
eval $COMMAND || exit 1
# Rebuild the search cache (lazily)
COMMAND="python3 netbox/manage.py reindex --lazy"
echo "Rebuilding search cache ($COMMAND)..."
eval $COMMAND || exit 1
# Delete any expired user sessions
COMMAND="python3 netbox/manage.py clearsessions"
echo "Removing expired user sessions ($COMMAND)..."