Hi
I have been trying to do my 1st install of commcare on a new vm Ubuntu 18.04.6 LTS.
I found several issue while running "commcare-cloud monolith deploy-stack --first-time -e 'CCHQ_IS_FRESH_INSTALL=1'"
1st issue was installing 'erlang-mode=1:19.3.6.13-1' this failed due to that version being unavailable, i managed to get round this by commenting out 'erlang-mode=1:19.3.6.13-1'
2nd issue was installing 'simpleeval==0.9.10' again commenting this out allowed the setup to continue
3rd issue was
TASK [commcarehq : Pull source repo (GitHub - dimagi/commcare-hq: CommCareHQ is the server backend for CommCare, the world's largest platform for designing, managing, and deploying robust, offline-first, mobile applications to frontline workers worldwide)] ************************************************************************************************
fatal: [192.168.2.195]: FAILED! => {"before": "5432e0d9fcc078bad2840c5337b3d936b2ff66af", "changed": false, "msg": "Local modifications exist in repository (force=no)."}
PLAY RECAP **********************************************************************************************************************************************************************
192.168.2.195: ok=381changed=21 unreachable=0failed=1skipped=306rescued=0ignored=3
✗ Apply failed with status code 2
this i fixed by running
'cchq monolith ap deploy_commcarehq.yml'
4th issue was
TASK [add "DigiCert SHA2 Secure Server CA" certificate to certifi] **************************************************************************************************************
fatal: [192.168.2.195]: FAILED! => {"changed": false, "msg": "Path /home/cchq/www/monolith/current/python_env-3.6/lib/python3.6/site-packages/certifi/cacert.pem does not exist !", "rc": 257}
PLAY RECAP **********************************************************************************************************************************************************************
192.168.2.195: ok=397changed=21 unreachable=0failed=1skipped=312rescued=0ignored=3
✗ Apply failed with status code 2
this i fixed by manualy creating the folders certifi and adding in the certificate which didn't exist and reruning'cchq monolith ap deploy_commcarehq.yml'
last issue was
TASK [Migrate DB] ***************************************************************************************************************************************************************
fatal: [192.168.2.195]: FAILED! => {"changed": false, "cmd": "./manage.py migrate_multi --noinput", "msg": "\n:stderr: Traceback (most recent call last):\nFile "./manage.py", line 5, in \nimport attr\nModuleNotFoundError: No module named 'attr'\n", "path": "/home/cchq/www/monolith/current/python_env-3.6/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin", "syspath": ["/tmp/ansible_django_manage_payload_eg8nx5in/ansible_django_manage_payload.zip", "", "/usr/lib/python36.zip", "/usr/lib/python3.6", "/usr/lib/python3.6/lib-dynload", "/usr/local/lib/python3.6/dist-packages", "/usr/lib/python3/dist-packages"]}
PLAY RECAP **********************************************************************************************************************************************************************
192.168.2.195: ok=583changed=65 unreachable=0failed=1skipped=418rescued=0ignored=3
✗ Apply failed with status code 2
i managed to get round this by commenting out 'migrate_on_fresh_install.yml'in deploy_stack.yml
i can now rerun "commcare-cloud monolith deploy-stack --skip-check -e 'CCHQ_IS_FRESH_INSTALL=1' and it will complete successfully.
i am now at the point of deploying CommCare HQ and this is where i can't continue due to the following error
commcare-cloud monolith django-manage create_kafka_topics
ssh phil@192.168.2.195 -t -o UserKnownHostsFile=/home/phil/environments/monolith/known_hosts 'sudo -iu cchq bash -c '"'"'cd /home/cchq/www/monolith/current; python_env-3.6/bin/python manage.py create_kafka_topics'"'"''
Ubuntu 18.04.6 LTS
Enter passphrase for key '/home/phil/.ssh/id_rsa':
Traceback (most recent call last):
File "manage.py", line 5, in
import attr
ModuleNotFoundError: No module named 'attr'
Connection to 192.168.2.195 closed.
and no matter what i try to run any command that refrences manage.py, which seems to most commands, fails with the same error.
I have tried manually adding attr module using PIP but the command still fails
if anyone has any idea's how to resolve the manage.py issue that would be great
thanks