How to config MFE from private gitlab

How can I create a plugins to add a MFE from a private gitlab repo?

Hi @ChaVietCode :slight_smile:

These instructions describe how to install requirements from private git repos:

https://docs.tutor.edly.io/configuration.html#installing-extra-requirements-from-private-repositories

Basically, it has you manually install the private plugin to your Tutor build, and then rebuild the docker image so it contains the plugin.

Does that help?

Thank you, I figured it out myself.

My MFE-plugin simple is:

import os

from dotenv import load_dotenv
from tutormfe.hooks import MFE_APPS


load_dotenv()
gitlab_username = os.getenv("GITLAB_USERNAME")
gitlab_password = os.getenv("GITLAB_PASSWORD")


@MFE_APPS.add()
def mfe_forks(mfes):
    mfes["authn"] = {
        "repository": f"https://{gitlab_username}:{gitlab_password}@gitlab.com/open_edx/frontend-app-authn.git",
        "version": "main",
        "port": 1999,
        "name": "authn",
    }
    return mfes
1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.