overhangio / tutor-mfe

This plugin makes it possible to easily add micro frontend (MFE) applications on top of an Open edX platform that runs with Tutor.
GNU Affero General Public License v3.0
22 stars 95 forks source link

Dev images are not automatically built as the README says #157

Closed bradenmacdonald closed 1 year ago

bradenmacdonald commented 1 year ago

Today I was trying to update my tutor nightly devstack and set up the course-authoring MFE in development mode.

I did a git pull on tutor and tutor-mfe, then per the instructions in the tutor-mfe readme I configured it like this:

tutor config save --append MOUNTS=/Users/me/tutor-devstack/frontend-app-course-authoring
tutor dev launch -I

But this failed with:

======================================================
        Starting the platform in detached mode
======================================================
...
[+] Running 3/3
 ✘ permissions Error
 ✘ course-authoring Error
 ✘ mfe Error
Error response from daemon: manifest for overhangio/openedx-course-authoring-dev:16.1.1-nightly not found: manifest unknown: manifest unknown

I tried tutor images build all, which I thought launch would have done for me anyways, and that fixed two of the errors, but I still saw:

======================================================
        Starting the platform in detached mode
======================================================
...
[+] Running 1/1
 ✘ course-authoring Error                                                                                                                                                                                   2.2s 
Error response from daemon: manifest for overhangio/openedx-course-authoring-dev:16.1.1-nightly not found: manifest unknown: manifest unknown

I then figured out that I needed to run tutor images build course-authoring-dev which fixed the issue. However, this requirement to manually build the images seems to contradict the README which says:

With this change, the "profile-dev" image will be automatically re-built during launch.

Perhaps the changes in https://github.com/overhangio/tutor-mfe/pull/137 made the image no longer automatically get built? Or is the README missing some instructions?


tutor version 16.1.3-nightly, tutor-mfe version 16.1.1 (nightly), MacOS ARM64

bradenmacdonald commented 1 year ago

Probably related: even after I did the above, it just got past one error, but the MFE wasn't actually working. I just saw this in the logs:

tutor_nightly_dev-course-authoring-1  | > @edx/frontend-app-course-authoring@0.1.0 start
tutor_nightly_dev-course-authoring-1  | > fedx-scripts webpack-dev-server --progress --config ./webpack.dev-tutor.config.js
tutor_nightly_dev-course-authoring-1  | 
tutor_nightly_dev-course-authoring-1  | sh: 1: fedx-scripts: not found

I then realized that there was no node_modules present at all, so I did tutor dev run course-authoring bash and npm install then restarted tutor dev, and then it worked.