Hi
I’m trying to setup a new install with ecommerce functionality from the start. I can get the core LMS & CMS running, but the quickstart command is consistently failing. The relevant part of the output is below.
This is on a completely fresh server install, so i’m assuming I’m missing something. I’ve completed the following steps:
- Brand new Ubuntu Server 20.04 install, fully updated
- Install docker, as per: https://docs.docker.com/engine/install/ubuntu
- Install docker compose, as: https://docs.docker.com/compose/install
- Added the user to the docker group, so not running as root. I’ve tested this, and docker runs fine without sudo / root.
- Installed tutor binary v10.0.2 (previously tried v10.0.0 and v10.0.1 as they were released)
- Enabled the discovery and ecommerce plugins
- Run tutor local quickstart
The LMS and CMS are running, and if I create a user everything seems fine. I can’t get to anything eccomerce though, and the ecommerce url returns a server error. If I disable the plugins and run quickstart everything works as expected, but re-enabling the plugins leads to the same errors.
Plugin ecommerce: running init for service ecommerce...
docker-compose -f /home/ubuntu/.local/share/tutor/env/local/docker-compose.yml -f /home/ubuntu/.local/share/tutor/env/local/docker-compose.prod.yml --project-name tutor_local -f /home/ubuntu/.local/share/tutor/env/local/docker-compose.jobs.yml run --rm ecommerce-job sh -e -c ./manage.py migrate --noinput
./manage.py oscar_populate_countries --initial-only
./manage.py create_or_update_site \
--site-id=1 \
--site-domain=ecommerce.test-jutapox-my.lightunwrapped.com:8130 \
--site-name=dev \
--partner-code=dev \
--partner-name="Open edX - development" \
--lms-url-root="http://test-jutapox-my.lightunwrapped.com:8000" \
--client-side-payment-processor=cybersource \
--payment-processors=cybersource,paypal \
--sso-client-id="ecommerce-sso-dev" \
--sso-client-secret="b4CMzEnV" \
--backend-service-client-id="ecommerce-dev" \
--backend-service-client-secret="p9K0fkl9" \
--from-email support@lightunwrapped.com \
--discovery_api_url=http://discovery.test-jutapox-my.lightunwrapped.com:8381/api/v1/
# Production site
./manage.py create_or_update_site \
--site-id=2 \
--site-domain=ecommerce.test-jutapox-my.lightunwrapped.com \
--site-name=prod \
--partner-code=openedx \
--partner-name="Open edX" \
--lms-url-root="https://test-jutapox-my.lightunwrapped.com" \
--lms-public-url-root="https://test-jutapox-my.lightunwrapped.com" \
--client-side-payment-processor=cybersource \
--payment-processors=cybersource,paypal \
--sso-client-id="ecommerce-sso" \
--sso-client-secret="b4CMzEnV" \
--backend-service-client-id="ecommerce" \
--backend-service-client-secret="p9K0fkl9" \
--from-email support@lightunwrapped.com \
--discovery_api_url=https://discovery.test-jutapox-my.lightunwrapped.com/api/v1/
Starting tutor_local_mysql_1 ... done
Traceback (most recent call last):
File "/openedx/venv/lib/python3.6/site-packages/django/core/management/base.py", line 323, in run_from_argv
self.execute(*args, **cmd_options)
File "/openedx/venv/lib/python3.6/site-packages/django/core/management/base.py", line 361, in execute
self.check()
File "/openedx/venv/lib/python3.6/site-packages/django/core/management/base.py", line 390, in check
include_deployment_checks=include_deployment_checks,
File "/openedx/venv/lib/python3.6/site-packages/django/core/management/commands/migrate.py", line 64, in _run_checks
issues = run_checks(tags=[Tags.database])
File "/openedx/venv/lib/python3.6/site-packages/django/core/checks/registry.py", line 72, in run_checks
new_errors = check(app_configs=app_configs)
File "/openedx/venv/lib/python3.6/site-packages/django/core/checks/database.py", line 9, in check_database_backends
for conn in connections.all():
File "/openedx/venv/lib/python3.6/site-packages/django/db/utils.py", line 216, in all
return [self[alias] for alias in self]
File "/openedx/venv/lib/python3.6/site-packages/django/db/utils.py", line 213, in __iter__
return iter(self.databases)
File "/openedx/venv/lib/python3.6/site-packages/django/utils/functional.py", line 80, in __get__
res = instance.__dict__[self.name] = self.func(instance)
File "/openedx/venv/lib/python3.6/site-packages/django/db/utils.py", line 147, in databases
self._databases = settings.DATABASES
File "/openedx/venv/lib/python3.6/site-packages/django/conf/__init__.py", line 79, in __getattr__
self._setup(name)
File "/openedx/venv/lib/python3.6/site-packages/django/conf/__init__.py", line 66, in _setup
self._wrapped = Settings(settings_module)
File "/openedx/venv/lib/python3.6/site-packages/django/conf/__init__.py", line 157, in __init__
mod = importlib.import_module(self.SETTINGS_MODULE)
File "/usr/lib/python3.6/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 994, in _gcd_import
File "<frozen importlib._bootstrap>", line 971, in _find_and_load
File "<frozen importlib._bootstrap>", line 953, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'ecommerce.settings.tutor'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "./manage.py", line 12, in <module>
execute_from_command_line(sys.argv)
File "/openedx/venv/lib/python3.6/site-packages/django/core/management/__init__.py", line 381, in execute_from_command_line
utility.execute()
File "/openedx/venv/lib/python3.6/site-packages/django/core/management/__init__.py", line 375, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/openedx/venv/lib/python3.6/site-packages/django/core/management/base.py", line 336, in run_from_argv
connections.close_all()
File "/openedx/venv/lib/python3.6/site-packages/django/db/utils.py", line 219, in close_all
for alias in self:
File "/openedx/venv/lib/python3.6/site-packages/django/db/utils.py", line 213, in __iter__
return iter(self.databases)
File "/openedx/venv/lib/python3.6/site-packages/django/utils/functional.py", line 80, in __get__
res = instance.__dict__[self.name] = self.func(instance)
File "/openedx/venv/lib/python3.6/site-packages/django/db/utils.py", line 147, in databases
self._databases = settings.DATABASES
File "/openedx/venv/lib/python3.6/site-packages/django/conf/__init__.py", line 79, in __getattr__
self._setup(name)
File "/openedx/venv/lib/python3.6/site-packages/django/conf/__init__.py", line 66, in _setup
self._wrapped = Settings(settings_module)
File "/openedx/venv/lib/python3.6/site-packages/django/conf/__init__.py", line 157, in __init__
mod = importlib.import_module(self.SETTINGS_MODULE)
File "/usr/lib/python3.6/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 994, in _gcd_import
File "<frozen importlib._bootstrap>", line 971, in _find_and_load
File "<frozen importlib._bootstrap>", line 953, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'ecommerce.settings.tutor'
Error: Command failed with status 1: docker-compose -f /home/ubuntu/.local/share/tutor/env/local/docker-compose.yml -f /home/ubuntu/.local/share/tutor/env/local/docker-compose.prod.yml --project-name tutor_local -f /home/ubuntu/.local/share/tutor/env/local/docker-compose.jobs.yml run --rm ecommerce-job sh -e -c ./manage.py migrate --noinput
./manage.py oscar_populate_countries --initial-only
./manage.py create_or_update_site \
--site-id=1 \
--site-domain=ecommerce.test-jutapox-my.lightunwrapped.com:8130 \
--site-name=dev \
--partner-code=dev \
--partner-name="Open edX - development" \
--lms-url-root="http://test-jutapox-my.lightunwrapped.com:8000" \
--client-side-payment-processor=cybersource \
--payment-processors=cybersource,paypal \
--sso-client-id="ecommerce-sso-dev" \
--sso-client-secret="b4CMzEnV" \
--backend-service-client-id="ecommerce-dev" \
--backend-service-client-secret="p9K0fkl9" \
--from-email support@lightunwrapped.com \
--discovery_api_url=http://discovery.test-jutapox-my.lightunwrapped.com:8381/api/v1/
# Production site
./manage.py create_or_update_site \
--site-id=2 \
--site-domain=ecommerce.test-jutapox-my.lightunwrapped.com \
--site-name=prod \
--partner-code=openedx \
--partner-name="Open edX" \
--lms-url-root="https://test-jutapox-my.lightunwrapped.com" \
--lms-public-url-root="https://test-jutapox-my.lightunwrapped.com" \
--client-side-payment-processor=cybersource \
--payment-processors=cybersource,paypal \
--sso-client-id="ecommerce-sso" \
--sso-client-secret="b4CMzEnV" \
--backend-service-client-id="ecommerce" \
--backend-service-client-secret="p9K0fkl9" \
--from-email support@lightunwrapped.com \
--discovery_api_url=https://discovery.test-jutapox-my.lightunwrapped.com/api/v1/