Skip to content

Commit 75cbc42

Browse files
committed
wip: docs: add a guide for running on a devstack
Private-ref: https://tasks.opencraft.com/browse/BB-9980
1 parent 03db4c7 commit 75cbc42

File tree

1 file changed

+44
-3
lines changed

1 file changed

+44
-3
lines changed

README.rst

Lines changed: 44 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,47 @@ If you have an already running platform, initialize this plugin with a command l
2020

2121
Or use ``tutor [local|dev|k8s] launch -I`` to re-launch the platform (takes much longer).
2222

23+
Tutor devstack setup guide
24+
--------------------------
25+
26+
This is a temporary guide to use this with the experimental Typesense search backends developed for Open edX.
27+
The backends are found at the following pull requests:
28+
29+
- Forum search: https://github.com/openedx/forum/pull/225
30+
- Course content and course overview search: https://github.com/openedx/edx-search/pull/222
31+
32+
To begin, install `Tutor Main <https://docs.tutor.edly.io/tutorials/main.html#main>`_, prepare a directory for the new devstack, and cd to it.
33+
Then you can follow these steps:
34+
35+
.. code-block:: bash
36+
37+
# Enable the Typesense Tutor plugin
38+
git clone https://github.com/open-craft/tutor-contrib-typesense
39+
pip install -e ./tutor-contrib-typesense
40+
tutor plugins enable typesense
41+
42+
# Enable the forum and mount the custom branch of forum
43+
tutor plugins enable forum
44+
git clone https://github.com/open-craft/forum.git
45+
git -C ./forum checkout samuel/typesense-backend
46+
tutor mounts add ./forum
47+
48+
# Mount the custom branch of edx-search
49+
git clone https://github.com/open-craft/edx-search.git
50+
git -C ./edx-search checkout typesense
51+
tutor mounts add ./edx-search
52+
53+
# Launch the devstack
54+
tutor images build openedx-dev
55+
tutor dev launch
56+
57+
# Initialise the courseware indexes (forum is initialised automatically)
58+
tutor dev exec lms ./manage.py lms shell -c "import search.typesense; search.typesense.delete_indexes(); search.typesense.create_indexes()"
59+
60+
# Continue with normal set up - eg. create a user, import a course
61+
tutor dev do createuser --staff --superuser admin admin@example.com --password password
62+
tutor dev do importdemocourse
63+
2364
Configuration
2465
-------------
2566

@@ -61,12 +102,12 @@ Development
61102

62103
Set up a python virtual environment, then you can install dependencies and run the tests like:
63104

64-
make install
65-
make test
105+
make install
106+
make test
66107

67108
After making some changes, you can run the auto formatter over the code for consistency:
68109

69-
make format
110+
make format
70111

71112

72113
Open edX integration

0 commit comments

Comments
 (0)