Can Open Edx Enterprise run with Tutor?

Before I spend time trying to get Enterprise to work I just want to know, can Open Edx Enterprise run with Tutor?

I am happy with a ‘yes’ or ‘no’ answer but any additional guidance not listed in the enterprise docs would be appreciated. Particularly if it needs to be enabled in config files, what is the enabler variable etc.

I currently don’t have eCommerce enabled as this project is for a not for profit, but we have multiple different organization’s that would value being able to enroll and report their own learners. So if an alternative can be advised, that would also be appreciated.

Thanks in advance

Hi @dancasey! I am not familiar with Open edX Enterprise. Can you please give me some pointers?
This means that Enterprise will not work out of the box with Tutor. However, it doesn’t mean that it will not work with Tutor: any Open edX component can work with Tutor, provided you create the right plugin. If you need support for creating such a plugin, please don’t hesitate to get in touch.

Perfect @regis thanks, I will try and get it set up but with the understanding that I might need to develop a plugin and so shouldn’t promise it as deliverable by next week :grin:

From the enterprise documentation. It would seem that it is shipped as part of edx-platform, and only requires configuring from Admin.

However, this blog post from opencraft from April 2020 (only checked the date now), states that “making use of all functionality provided by the Open edX Enterprise Service requires a working setup of ecommerce and course-discovery”.

I will set some time aside for trying to integrate in enterprise in the coming weeks, and will report back with any issues and hopefully any solutions

@dancasey did enterprise work with tutor?? I have done all required backend configuration (catalogue + tutor e-commerce is running) but unable to access the site >

I was trying to map :: new_org.localhost (*in local environment) to test this but it didn’t work. Please let me know your thoughts.

@regis : running at 3.12. version of tutor

Thanks
Venkat.S

@venkat.330 I am only getting back to look at this today. I will configure catalogue + tutor e-commerce, and let you know how I get on.

Thanks, we are still trying to understand this.
@dancasey
however, in the local environment added “new_org.localhost” in nginx.conf to allow request and we were able to see catalogue. your thoughts and workflow would be helpful.

Thanks
Venkat

@venkat.330

Where did you add “new_org.localhost”? I don’t see nginx.conf, but can see env/apps/nginx/extra.conf
Where are you now seeing the catalogue?

I am struggling with getting my LMS (localhost) to communicate with the discover app.

Could you advice if we have configured in similar ways or if there are anythings I’ve missed?

I am running tutor V3.12.5, which is running inside a venv.

Steps taken:

  1. Enabled discover and ecommerce
    $ tutor plugins enable discovery ecommerce
    $ tutor local quickstart

  2. Created super users for both discover and ecommerce
    $ tutor local run ecommerce ./manage.py createsuperuser
    $ tutor local run discovery ./manage.py createsuperuser

  3. Checked applications were running by navigating to http://discovery.localhost and http://ecommerce.localhost. Both look to be running with access to the admin panels after login in

  4. Add new catalogue in discovery containing all courses - http://discovery.localhost/admin/catalogs/catalog/add/
    Name: myCat
    Query: GET /api/v1/search/courses

  5. Add new enterprise customer - http://localhost/admin/enterprise/enterprisecustomer/add/
    No catalogues listed in the drop down selector.
    Clicking ‘Create a new catalogue’ attempts to go to http://discovery:8000/admin/catalogs/catalog/add/, but returns ‘server not found’
    Expected it to point at discover.localhost

  6. Add Catalog integration - http://localhost/admin/catalog/catalogintegration/add/
    Set Internal API URL: http://discovery.localhost/api/v1
    Prompt states DEPRECATED: Use the setting COURSE_CATALOG_API_URL

  7. Check if catalogue is visible at http://localhost/admin/enterprise/enterprisecustomer/add/
    Catalogues are now visible but ‘View catalog …’ and Create a new catalog’ still point to ‘discover:8000’

  8. Set COURSE_CATALOG_API_URL = "http://discovery:8000" as suggested [here] (Lms <-> discovery communication). First tried this by setting in cms.env.json and lms.env.json, but then
    Ran
    $ tutor config printvalue COURSE_CATALOG_API_URL
    and got http://discovery.localhost.
    Ran
    $ tutor config save --set COURSE_CATALOG_API_URL=“http://discovery:8000
    $ tutor config printvalue COURSE_CATALOG_API_URL
    and got http://discovery:8000

    http://discover:8000 still responds with ‘Server not found’

[quote=“dancasey, post:7, topic:645, full:true”]
@venkat.330

Where did you add “new_org.localhost”? I don’t see nginx.conf, but can see env/apps/nginx/extra.conf
Where are you now seeing the catalogue?

tutor/env/apps/nginx/lms.conf

added

server {
listen 80;
server_name localhost preview.localhost new_org.localhost ;

Rest other config looks ok for me… also

can you set COURSE_CATALOG_API_URL as http://discovery.localhost. , it should work make sure *new_org.localhost is allowed host of your LMS conf (JSON / prodcution.py) :: just for testing

Edited tutor/env/app/nginx/lms.conf:

  server { 
  listen 80; 
  server_name localhost preview.localhost new_org.localhost; 

Edited tutor/env/apss/openeds/settings/lms/production.py

COURSE_CATALOG_API_URL = "http://discovery.localhost"

ALLOWED_HOSTS = [
    ENV_TOKENS.get("LMS_BASE"),
    FEATURES["PREVIEW_LMS_BASE"],
    "lms",
    "127.0.0.1",
    "localhost",
    "preview.localhost",
    "new_org.localhost",
]

Navigated to - http://localhost/admin/enterprise/enterprisecustomer/add/

‘Create a new catalog’ link now successfully navigates to http://discovery.localhost/admin/catalogs/catalog/add/ but the catalog is not then listed in the dropdown.

@venkat.330
Are you able to select a catalog when adding a new enterprise customer?
What enterprise documentation are you using? (The documentation found via github, seems pretty out of date)

did you index your courses ??

to understand catlouges further:: you can run kibana instance for trouble shooting purpose

docker run -d --name kibana_local --net tutor_local_default -p 5601:5601 -e ELASTICSEARCH_URL=http://elasticsearch:9200 kibana:4.1.3

Thanks @venkat.330, I have yet to dive into the world of elasticsearch and kibana, and beginning to think I might be biting off more than I can chew tackling this.

I will do a bit more research using the links you provided and decide whether our project really needs the added complexity of Enterprise (since Tutor has been be pretty simple so far). All I really want to achieve is separate reporting for a number of different groups, by a group reporter that is not STAFF. Maybe a hack of Figures, but that would be another learning curve for another forum thread :roll_eyes:

The following is only an FYI and as I said I should probably do more research.

Running

$ tutor local run discovery ./manage.py refresh_course_metadata --partner_code=openedx

Returns error

requests.exceptions.ConnectionError: HTTPConnectionPool(host=‘www.myopenedx.com’, port=80): Max retries exceeded with url: /oauth2/access_token (Caused by NewConnectionError(’<requests.packages.urllib3.connection.HTTPConnection object at 0x7fd8896c4860>: Failed to establish a new connection: [Errno -2] Name or service not known’,))
Error: Command failed with status 1: docker-compose -f /home/dan/ClimateIreland/CIL/tutor/env/local/docker-compose.yml --project-name tutor_local run --rm discovery ./manage.py refresh_course_metadata --partner_code=openedx

I presume because www.myopenedx.com doesn’t actually exist.

But when I run a blank query from http://discovery.localhost/, it successfully returns the single course on my platform…so just presumed the courses were indexed and searchable.

Even I am exploring what can be done with entriprise. It looks to be to attractive and think will be an effective feature to use in edx considering we should know to use catalogue & course_runs properly.