Configuring and managing multiple sites in a single Open edX installation is really tricky. To set up a custom site, there are configurations that need to be set in multiple services (LMS, Discovery, and eCommerce). And if we change some of these configurations in some service, we will need to remember to change them to other services as well. And there is some config that gets reset during deployment.
So we came up with some scripts that can do this automatically based on a configuration file. These scripts are meant to be run on an App Server. Because they use python env and Django models from those services.
This config.yaml (sample) is meant to be tracked in Git (ex - configuration-secure repositories). And rather than setting up Custom site config in multiple services, we specify them in this config file.
Full detailed documentation on how to use this can be found in the Readme.md file.
Kudos to @farhaan & @guruprasad for reviewing those scripts and providing helpful insights.
@shimulch, kudos on the outstanding work that you have done for this! The only suggestion that I have for this one (one that I have already mentioned it to you before) is to rename the repository and the tool to something better since “microsites” is the name of a deprecated feature in the platform.
Something like site-configuration-generator would be better, imho. But let’s not rush into making the changes for this if it requires a non-trivial amount of effort and time.
@guruprasad, @braden thanks for the link. I didn’t know that an old feature had that name.
@Fox, I’ve tried to import the repo in our GitLab. But seems I can’t import a project under opencraft/dev group in GitLab due to permissions I guess. I’ve imported it here - https://gitlab.com/opencraft/core/sites-generator
Can anyone with correct permission move it to the opencraft/dev group?
I will open an MR after the transfer to make changes in README.md.
@shimulch, @farhaan, I think it might be a good idea to combine this tool with the terraform scripts that we have created for setting up the related resources on AWS to provide it as a complete solution. What do you think?
@shimulch very nice work :) I think we should definitely have a blog post about this. Would you be up for writing one sometime soon, to strike the iron while it’s hot? You can follow this procedure and schedule a ticket in one of your sprints, with me as 2nd reviewer. Let me know if that would work for you?
The project has been moved to GitLab and the Github one is archived.
@daniel Added a ticket to log time. BB-4690. Thanks for pointing that out.
I think it might be a good idea to combine this tool with the terraform scripts that we have created for setting up the related resources on AWS to provide it as a complete solution. What do you think?