Hi Ed
This is a tricky one, I think what has likely happened is that the localsettings.py file is out of sync with the code.
The simplest thing might actually be to set up CommCare on the machine from scratch. You could do this by renaming the /home/cchq/monolith
directory to /home/cchq/monolith_backup
and then running Ansible to re-create the setup:
cchq monolith ap deploy_commcarehq.yml