Tutor [Palm]: How to bind-mount a local MFE folder

Hi Adolfo, thanks for your reply. Perhaps we need to break this out into a separate topic, something like “Tutor [Palm]: How to bind-mount a local MFE folder”

I have tried a few different approaches to get this working successfully, and have had no luck… yet.

tutor config save --append MOUNTS=/path/to/my/local/mfe/profile
tutor dev launch

and also

tutor mounts add /path/to/my/local/mfe/profile
tutor dev launch

In both instances, I see my config.yml has the following:

MOUNTS:
- /path/to/my/local/mfe/profile

tutor mounts list shows:

- name: /path/to/my/local/mfe/profile
  build_mounts: []
  compose_mounts: []

But every time I launch dev, the profile page does not show any of my local changes.

What am I missing?

Your first option is the correct one, and should’ve worked as per the documentation.

Can you maybe post the launch logs on a gist or somewhere?

Also, what version of Tutor are you running?

Hi @arbrandes thanks for your quick response. I’m running Tutor 16.0.2.

I figured out why it wasn’t working for me - when I created the MFE forks for my org, I changed the name of the fork to something other than frontend-app-profile, etc. If the name doesn’t exactly match the upstream repo letter-for-letter, word-for-word, the bind-mount simply won’t work.

Also, because the documentation for frontend-app-profile says devstack needs to be started first, I assumed the same should be true for tutor. Instead, one has to start the local MFE first with npm run start and once it’s running, follow up with tutor dev launch.

I think it would be good to update the documentation for the tutor MFE plugin, as well as each individual MFE, to include more specific details about what missteps to avoid, and how to get everything running. To that end, I’ll work on a series of pull requests to help that along. I’ll follow up here once they’re ready for review.

Thanks again for your response.

2 Likes

That’s correct, and as you mention below, likely warrants an update to the docs if it’s not clear enough.

As far as I know, tutor-mfe won’t actually use the npm run started node that’s running outside the container, but I imagine this works because as part of npm run start the MFE gets re-built. In any case, what I’m trying to say is that npm run start shouldn’t be necessary.

That would be awesome. Thanks!

Hi @arbrandes & @regis,
I’ve opened a PR against the master branch of the Tutor MFE repo.

1 Like

@rediris after mounting edx-platfrom successfully in Quince I will try the same way to mount the learner dashboard but I am facing this issue. I also checked Docker and I don’t think there is a problem there.

tutor mounts add /home/yagnesh/tvm-quin/frontend-app-learner-dashboard
tutor dev launch
[v17.0.0@tvm-quin] yagnesh@DSK-DEL-00001:~/tvm-quin$ tutor mounts list
- name: /home/yagnesh/tvm-quin/edx-platform
  build_mounts:
  - image: openedx
    context: edx-platform
  - image: openedx-dev
    context: edx-platform
  compose_mounts:
  - service: openedx
    container_path: /openedx/edx-platform

[v17.0.0@tvm-quin] yagnesh@DSK-DEL-00001:~/tvm-quin$ tutor mounts add /home/yagnesh/tvm-quin/frontend-app-learner-dashboard
Adding bind-mount: /home/yagnesh/tvm-quin/frontend-app-learner-dashboard
Configuration saved to /home/yagnesh/tvm-quin/config.yml
Environment generated in /home/yagnesh/tvm-quin/env
[v17.0.0@tvm-quin] yagnesh@DSK-DEL-00001:~/tvm-quin$ tutor dev start -d
docker compose -f /home/yagnesh/tvm-quin/env/local/docker-compose.yml -f /home/yagnesh/tvm-quin/env/local/docker-compose.prod.yml --project-name tutor_local stop
docker compose -f /home/yagnesh/tvm-quin/env/local/docker-compose.yml -f /home/yagnesh/tvm-quin/env/dev/docker-compose.yml --project-name tutor_dev up --remove-orphans -d
[+] Running 0/1
 ⠿ learner-dashboard Error                                                                                                                                                                            2.6s
Error response from daemon: pull access denied for overhangio/openedx-learner-dashboard-dev, repository does not exist or may require 'docker login': denied: requested access to the resource is denied
Error: Command failed with status 18: docker compose -f /home/yagnesh/tvm-quin/env/local/docker-compose.yml -f /home/yagnesh/tvm-quin/env/dev/docker-compose.yml --project-name tutor_dev up --remove-orphans -d
[v17.0.0@tvm-quin] yagnesh@DSK-DEL-00001:~/tvm-quin$ tutor dev launch