SUNScholar/XMLUI Theme/M2

From Libopedia
Jump to: navigation, search
Back to XMLUI Theme

Introduction

This is a very brief installation guide for the new Mirage2 theme released with DSpace version 5.

EIFL Webinar

Please view the following webinar before continuing.

PLEASE NOTE:

  1. Please make sure that the server is able to download software dependencies from the internet during the maven build process.
  2. If your interent is intermittent, then it is probably wise not to use the Mirage 2 theme, but rather stay with the Mirage 1 theme for better stability.
  3. It is assumed that you installed DSpace according to:
    http://wiki.lib.sun.ac.za/index.php/SUNScholar/DSpace
  4. Mirage 2 with DSpace => 5.X requires Ubuntu 14.04.
  5. If you want to upgrade to 14.04 LTS, then check:
    http://wiki.lib.sun.ac.za/index.php/SUNScholar/Upgrading/Server_Software

Requirements

  1. Use port 80 and 443 as default on the Tomcat Java webapp server.
  2. Configure chosen UI as the default ROOT Java webapp.

Install Ubuntu Software

  • After logging in as the "dspace" user, install the required Ubuntu software, by typing the following:
sudo apt-get install git curl maven ruby-compass default-jdk default-jre

Enable Github Downloads

git config --global url."https://".insteadOf git://

Step 1 - Install Non-Ubuntu Packaged Software

Step 1.1

  • Install the "node.js" software, by typing the following:
sudo curl -sL https://deb.nodesource.com/setup | sudo bash -

Follow the onscreen after installation instructions.

Step 1.2

  • Install the node version manager (nvm) software, by typing the following:
sudo curl https://raw.githubusercontent.com/creationix/nvm/v0.24.0/install.sh | bash

Follow the onscreen after installation instructions.

Step 1.3

  • Install the ruby version manager (rvm) software, by typing the following:
sudo curl -sSL https://get.rvm.io | bash -s stable

Follow the onscreen after installation instructions.

Step 2 - Install Theme Build Software

  • When the above software above has been installed correctly, then logout and login again as the "dspace" user.
  • Type the following to install the software required to customise and build the theme:
sudo -i
npm install --no-check-certificate -g bower
npm install --no-check-certificate -g grunt
npm install --no-check-certificate -g grunt-cli
exit

Step 3 - Build Theme

Type the following;

cd $HOME/source

Full Build With Dependency Downloads

mvn -U clean package -Dmirage2.on=true

See example build report below.

[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO] 
[INFO] DSpace Parent Project ............................. SUCCESS [5.717s]
[INFO] DSpace Services Framework :: API and Implementation  SUCCESS [1.557s]
[INFO] DSpace Kernel :: API and Implementation ........... SUCCESS [5.619s]
[INFO] DSpace Addon Modules .............................. SUCCESS [0.048s]
[INFO] DSpace Kernel :: Additions and Local Customizations  SUCCESS [3.098s]
[INFO] DSpace XML-UI (Manakin) ........................... SUCCESS [2.737s]
[INFO] DSpace XML-UI Mirage2 Theme ....................... SUCCESS [0.209s]
[INFO] DSpace XML-UI Mirage2 Theme :: Local Customisations  SUCCESS [3:32.133s]
[INFO] DSpace XML-UI (Manakin) :: Local Customizations ... SUCCESS [13.554s]
[INFO] DSpace JSP-UI ..................................... SUCCESS [2.898s]
[INFO] DSpace JSP-UI :: Local Customizations ............. SUCCESS [4.898s]
[INFO] DSpace RDF ........................................ SUCCESS [3.811s]
[INFO] DSpace RDF :: Local Customizations ................ SUCCESS [5.349s]
[INFO] DSpace REST :: API and Implementation ............. SUCCESS [4.596s]
[INFO] DSpace REST :: Local Customizations ............... SUCCESS [5.610s]
[INFO] DSpace SWORD ...................................... SUCCESS [2.005s]
[INFO] DSpace SWORD :: Local Customizations .............. SUCCESS [4.508s]
[INFO] DSpace SWORD v2 ................................... SUCCESS [4.027s]
[INFO] DSpace SWORD v2 :: Local Customizations ........... SUCCESS [3.948s]
[INFO] Apache Solr Webapp ................................ SUCCESS [16.859s]
[INFO] DSpace SOLR :: Local Customizations ............... SUCCESS [6.708s]
[INFO] DSpace OAI-PMH .................................... SUCCESS [5.272s]
[INFO] DSpace OAI-PMH :: Local Customizations ............ SUCCESS [4.985s]
[INFO] DSpace Assembly and Configuration ................. SUCCESS [40.124s]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 6:00.947s
[INFO] Finished at: Thu Apr 02 10:27:29 SAST 2015
[INFO] Final Memory: 78M/392M
[INFO] ------------------------------------------------------------------------

Update Regular Rebuild DSpace Script

If you want to use the Mirage2 theme permanently, then make sure to add the Mirage2 build switch to your DSpace rebuild script.

  • For example;
mvn -U clean package -Dmirage2.on=true

Step 4 - Activate Theme

  • Type the following:
nano $HOME/source/dspace/config/xmlui.xconf
  • Add the following to the "<themes>" section:
<theme name="Mirage 2" regex=".*" path="Mirage2/" />

Check that the "Mirage2" theme is the ONLY active theme and is NOT enclosed with <!-- .... -->.

Save and exit the file.

Example Themes Section

   <themes>
        <!-- Example configuration -->

        <!-- <theme name="Test Theme 1" handle="123456789/1" path="theme1/"/>    -->
        <!-- <theme name="Test Theme 2" regex="community-list" path="theme2/"/> -->

        <!-- Mirage theme, @mire contributed theme, default since DSpace 3.0 -->
        <!-- <theme name="Atmire Mirage Theme" regex=".*" path="Mirage/" /> -->
             <theme name="Atmire Mirage 2 Theme" regex=".*" path="Mirage2/" />

        <!-- Reference theme, the default Manakin XMLUI layout up to DSpace 1.8 -->
        <!-- <theme name="Default Reference Theme" regex=".*" path="Reference/" /> -->

        <!-- Classic theme, inspired by the JSP UI -->
        <!-- <theme name="Classic" regex=".*" path="Classic/" /> -->

        <!-- The Kubrick theme -->
        <!-- <theme name="Kubrick" regex=".*" path="Kubrick/" /> -->

        <!--
             For information on configuring the mobile theme, see:
             dspace-xmlui/src/main/webapp/themes/mobile/readme.txt
        -->
    </themes>

Step 5 - Customise Theme

Click on the heading above.

Build Issues Troubleshooting

References