integ/utilities/branding/sources/horizon
Scott Little d516de57ad Relocate wrs-branding to stx-integ/utilities/branding
Move content from stx-utils into stx-integ or stx-update

Packages will be relocated to

stx-update:
    enable-dev-patch
    extras

stx-integ:
    config-files/
        io-scheduler

    filesystem/
        filesystem-scripts

    grub/
        grubby

    logging/
        logmgmt

    tools/
        collector
        monitor-tools

    tools/engtools/
        hostdata-collectors
        parsers

    utilities/
        build-info
        branding   (formerly wrs-branding)
        platform-util

Change-Id: I40b3c3cdd4a8e7b93f2436ff1c1d4c37317a1bf2
Story: 2002801
Task: 22687
Signed-off-by: Scott Little <scott.little@windriver.com>
2018-08-01 12:21:57 -04:00
..
README Relocate wrs-branding to stx-integ/utilities/branding 2018-08-01 12:21:57 -04:00
sample_branding.tgz Relocate wrs-branding to stx-integ/utilities/branding 2018-08-01 12:21:57 -04:00

Copyright © 2014-2017 Wind River Systems, Inc.

SPDX-License-Identifier: Apache-2.0
-----------------------------------------------------------------------


Titanium Cloud Custom Branding
-------------------------------

Custom branding for the Titanium Cloud is achieved through the creation and application
of a tarball containing a customized horizon theme and associated branding files


Creating a Custom Branding Tarball
----------------------------------

The tarball containing the customized branding files must be of the extension .tgz; its 
file name has no constraints.  'sample_branding.tgz' has been included as an example of 
the end result.  Please note that branding tarballs created for previous releases of
Titanium Cloud are not forward-compatible, and must be recreated to accommodate the
latest branding styles present in Horizon.  An example of how to compress an existing
theme would be to do the following from inside the branding's root directory:
    tar czf new_branding.tgz *

Two types of items are required in the branding tarball:
    1) The contents of a valid horizon theme directory as documented here:
           docs.openstack.org/developer/horizon/topics/customizing.html
       i.e. in the top level of the tarball are the theme folders 'static' and 'templates' (if used).
       Both the default and material themes included with horizon are available to be
       inherited from if desired.  Note that when referencing assets included in the custom theme,
       the theme name will be 'custom'.

       To base the new theme off of the standard titanium cloud theme, or to view an example
       of how the tarball should be formatted, refer to the example tarball named
       sample_branding.tgz included with this SDK.

	2) Also in the top level of the tarball, a file named manifest.py which is used to overwrite the default
       horizon settings used by Titanium Cloud.  A description of its contents are as follows:

	       SITE_BRANDING is the name that will be used in the site title, note that there are
	       other occurrences of the branding name that must be changed directly in the templates,

	       HORIZON_CONFIG["help_url"] is the link that the help button will redirect
           users to, note that the knowledge library url must also be changed directly in
           the template,

	       Sample entries for these variables are shown below:

               SITE_BRANDING = "Sample System Name"
               HORIZON_CONFIG["help_url"] = "http://www.windriver.com/support/"


Applying a Custom Branding Tarball
----------------------------------

This branding tarball can be applied at various stages, the steps for each stage are 
described below:

	1) Before running config_controller
		i) Copy the branding tarball to the /opt/branding directory, once config_controller 
           is run this branding will be automatically used by horizon
		
	2) After running config_controller
		i)   If a previous branding tarball was already in use, 
             delete it from /opt/branding,
		ii)  Copy the new branding tarball to the /opt/branding directory on the 
             active controller,
		iii) Execute the command 
                 sudo service horizon restart 
             this will process the new branding files on the active controller,
		iv)  Lock the inactive controller,
		v)   Unlock the inactive controller.
             lock and unlock can coincide with login banner customization, see
             also README.banner