OSC / ondemand

Supercomputing. Seamlessly. Open, Interactive HPC Via the Web
https://openondemand.org/
MIT License
287 stars 106 forks source link

Branding Customizations - Support branding customizations based on profiles #2149

Closed abujeda closed 2 years ago

abujeda commented 2 years ago

At IQSS, we have a requirement to support different look and feel for different departments. Moving the existing branding customizations to new profile feature will allow us to implement some of these requirements.

Definition of Done Move the following environment values from ConfigurationSingleton to UserConfiguration

Update the UserConfiguration functionality to read from the ENV object first before using the config object data. Values in the ENV object will have precedence over values in the config object.

Update all references to these values from the ConfigurationSingleton to the new UserConfiguration object.

┆Issue is synchronized with this Asana task by Unito

abujeda commented 2 years ago

We have started working on this feature. Draft PR coming shortly

johrstrom commented 2 years ago

One thing on implantation that I'd expect is moving all these env variables to string_configs if they're simple. I.e, default or value. some have more complicated toggling logic. If that's the case, they can have their own function, but I'd say most can move here.

https://github.com/OSC/ondemand/blob/a66892f2d93af77cdbc478bb583fd3b7bc754166/apps/dashboard/config/configuration_singleton.rb#L54-L59

abujeda commented 2 years ago

I was actually updating the implementation of the UserConfiguration based on the string_configs feature from ConfigurationSingleton. More details with the PR soon.

johrstrom commented 2 years ago

I see, you just duplicate the same blocks. That could work too.

abujeda commented 2 years ago

Just to be on the same page. These are the changes: https://github.com/OSC/ondemand/pull/2151

Still work in progress and not completed, but the general idea is there. Let me know what you think.

abujeda commented 2 years ago

Small demo of what is possible with the OnDemand Branding setup using the new profile based configuration:

branding

johrstrom commented 2 years ago

This was fixed in #2151.