Hi, I want to override the @frontend-app-authn mfe and use the @edx/brand-edx package to customize the login page to remove the register button and page and make changes to the css of the page.
Tutor version: 17.0.5
MFE version: 17.0.1
Redirecting to login page:
I used the admin portal to redirect the lms user to login page.
Removing public registration functionality:
I created a tutor plugin to do this and it work fine.
Then, I did the following:
- Fork frontend-app-authn repo
- Clone repo to local computer
- cd dev-env
- git clone https://github.com/my-repo/frontend-app-authn.git
- Bind-mount folder
- tutor mounts add dev-env/frontend-app-authn
- tutor mounts list
- Fork openedx/brand repo
- Clone repo to local computer
- cd .local/share/tutor/env/build/openedx/themes
- git clone https://github.com/my-repo/my-brand.git # this is the edx/brand-edx repo
- Start my environment
tutor dev start authn
The cms is working but the lms site can’t be reached.
When I see the authn logs using tutor dev log authn, I get this:
So, I thought that the dependencies are not installed. Therefore I installed npm in the frontend-app-authn directory that I had cloned.
cd dev-env/frontend-app-authn
npm install
There were some warning of deprecation but no errors.
Then I did
tutor config save
tutor images build authn
tutor dev start
and got a new error:
This is what a complete section of the authn logs looks like:
@edx/frontend-app-authn@0.1.0 start
authn-1 | > fedx-scripts webpack-dev-server --progress --config ./webpack.dev-tutor.config.js
authn-1 |
authn-1 | [webpack-cli] Failed to load ‘/openedx/app/webpack.dev-tutor.config.js’ config
authn-1 | [webpack-cli] Error: Cannot find module ‘@edx/frontend-build/config/webpack.dev.config.js’
authn-1 | Require stack:
authn-1 | - /openedx/app/webpack.dev-tutor.config.js
authn-1 | - /openedx/app/node_modules/webpack-cli/lib/webpack-cli.js
authn-1 | - /openedx/app/node_modules/webpack-cli/lib/bootstrap.js
authn-1 | - /openedx/app/node_modules/webpack-cli/bin/cli.js
authn-1 | - /openedx/app/node_modules/webpack-dev-server/bin/webpack-dev-server.js
authn-1 | - /openedx/app/node_modules/@openedx/frontend-build/bin/fedx-scripts.js
authn-1 | at Module._resolveFilename (node:internal/modules/cjs/loader:1134:15)
authn-1 | at Module._load (node:internal/modules/cjs/loader:975:27)
authn-1 | at Module.require (node:internal/modules/cjs/loader:1225:19)
authn-1 | at require (node:internal/modules/helpers:177:18)
authn-1 | at Object. (/openedx/app/webpack.dev-tutor.config.js:7:7)
authn-1 | at Module._compile (node:internal/modules/cjs/loader:1356:14)
authn-1 | at Module._extensions…js (node:internal/modules/cjs/loader:1414:10)
authn-1 | at Module.load (node:internal/modules/cjs/loader:1197:32)
authn-1 | at Module._load (node:internal/modules/cjs/loader:1013:12)
authn-1 | at Module.require (node:internal/modules/cjs/loader:1225:19) {
authn-1 | code: ‘MODULE_NOT_FOUND’,
authn-1 | requireStack: [
authn-1 | ‘/openedx/app/webpack.dev-tutor.config.js’,
authn-1 | ‘/openedx/app/node_modules/webpack-cli/lib/webpack-cli.js’,
authn-1 | ‘/openedx/app/node_modules/webpack-cli/lib/bootstrap.js’,
authn-1 | ‘/openedx/app/node_modules/webpack-cli/bin/cli.js’,
authn-1 | ‘/openedx/app/node_modules/webpack-dev-server/bin/webpack-dev-server.js’,
authn-1 | ‘/openedx/app/node_modules/@openedx/frontend-build/bin/fedx-scripts.js’
I am not exactly sure but I think it cannot find the repo @edx/frontend-build because it has been moved to @openedx/frontend-build. To begin with, I do not understand why it is trying to find the @edx/frontend-build repo. I think it should try to find the @openedx/frontend-build. If this is how it should work, how can I fix this issue. I am new to openedx and tutor and I am not sure if I am missing something or doing something wrong. I need help fixing this issue.
Thank you in advance.