2

How do I install and enable my custom theme in OpenEdx's docker based DevStack?

  • I use comprehensive theming
  • I use docker on Linux
coder
  • 8,346
  • 16
  • 39
  • 53
Morpheus.47
  • 131
  • 2
  • 10
  • 7
    Welcome to SO. Please read the guidelines on [how to ask](https://stackoverflow.com/help/asking) a good question and update yours accordingly. As it is currently written, it may be closed as a "too broad" question. – tgogos Jul 16 '18 at 07:35
  • 1
    Welcome! Please be more specific and show what you have tried so far. – petezurich Jul 16 '18 at 10:51

1 Answers1

1

The LMS and CMS read many configuration settings from the container filesystem in the following locations:

/edx/app/edxapp/cms.env.json

/edx/app/edxapp/cms.auth.json

Since you are using docker DevStack, shell into LMS, CMS to find those files.

shell into LMS

make lms-shell

Shell into CMS

make studio-shell

You can create this directory at any location on a file system that is accessible to your Open edX installation. For example, you might place it at the root of the file system in a directory named /my-open-edx-themes.

Set the file permissions on the themes directory, and all of its subdirectories, to enable read+write permissions for the Ubuntu user.

sudo chown -R edxapp:edxapp /my-open-edx-themes
sudo chmod -R u+rw /my-open-edx-themes

For each Open edX component that you want to theme, set the

"ENABLE_COMPREHENSIVE_THEMING" = True

"DEFAULT_SITE_THEME": "Your-theme-name "

For LMS,

/edx/app/edxapp/lms.env.json

For Studio,

/edx/app/edxapp/cms.env.json

For the E-commerce,

/edx/etc/ecommerce.yml

And for each Open edX component that you want to apply a theme to, add the absolute path of the themes directory to the

COMPREHENSIVE_THEME_DIRS

configuration property.

For LMS and Studio,

"COMPREHENSIVE_THEME_DIRS": [
    "/my-open-edx-themes/edx-platform"
]

For the E-commerce,

COMPREHENSIVE_THEME_DIRS: ["/my-open-edx-themes/ecommerce"]

Finally, Restart all servers.

For more info, please follow this documentation.

http://edx.readthedocs.io/projects/edx-installing-configuring-and-running/en/latest/configuration/changing_appearance/theming/enable_themes.html

Add comments if you have any additional questions.

Community
  • 1
  • 1
Isanka Wijerathne
  • 3,746
  • 3
  • 26
  • 34
  • I believe the question is how to persist the settings in docker since the theme configuration is not persisted once docker is restarted. – asamolion Jan 01 '19 at 13:42