+ - 0:00:00
Notes for current slide

Presenter notes contain extra information which might be useful if you intend to use these slides for teaching.

Press P again to switch presenter notes off

Press C to create a new window where the same presentation will be displayed. This window is linked to the main window. Changing slides on one will cause the slide to change on the other.

Useful when presenting.

Notes for next slide



Advanced customisation of a Galaxy instance



last_modification Updated:   purlPURL: gxy.io/GTN:S00000

text-document Plain-text slides |

Tip: press P to view the presenter notes | arrow-keys Use arrow keys to move between slides
1 / 27

Presenter notes contain extra information which might be useful if you intend to use these slides for teaching.

Press P again to switch presenter notes off

Press C to create a new window where the same presentation will be displayed. This window is linked to the main window. Changing slides on one will cause the slide to change on the other.

Useful when presenting.

Setup

We are going to use a prebuilt virtual machine image for this session.

From the given USB stick, please:

  • Copy and install VirtualBox (or download) if you do not have it already.
  • Copy the Planemo machine image - file latest.ova or download.
2 / 27

Galaxy's frontend

JavaScript sources and CSS sources are in the $GALAXY_ROOT/client folder.

Whenever you make changes there, you will need to re-build Galaxy's frontend with:

$ cd $GALAXY_ROOT
$ make client

This requires Node.

3 / 27

Translation and localisation 1/2

The language for labels used in the JS source code is English, but can be wrapped in l() which makes it translatable.

_l( 'Help' )
4 / 27

Translation and localisation 1/2

The language for labels used in the JS source code is English, but can be wrapped in l() which makes it translatable.

_l( 'Help' )
"Analyze Data" :
false,
5 / 27

Translation and localisation 1/2

The language for labels used in the JS source code is English, but can be wrapped in l() which makes it translatable.

_l( 'Help' )
"Analyze Data" :
false,
  • There is a folder client/galaxy/scripts/nls/ that contains all available localisations.
    "Analyze Data" :
    "Analyse de données",
6 / 27

Translation and localisation 2/2

When a user's browser locale or language is set to a known translation, it will be used instead of the default. If a translation is not available for a string, it will appear in English.

7 / 27

How to modify the menu

Open the client/galaxy/scripts/layout/menu.js

var helpTab = {
id : 'help',
title : _l('Help'),
tooltip : _l('Support, contact, and community'),
menu : [{
title : _l('Support'),
url : options.support_url,
target : '_blank'
},{
title : _l('Search'),
url : options.search_url,
target : '_blank'
8 / 27

Configuration tweaks

Plenty of customisation can be achieved using settings in the main configuration file galaxy.yml

9 / 27

Tool Panel configuration

  • How the tool panel looks like is decided in a file called integrated_tool_panel.xml.
  • By default it resides in Galaxy's root folder.
  • If missing it is generated from all other tool config files during startup.
  • Modify it if you want to reorder tools or move sections.
10 / 27

Tool panel labels

You can add <tool labels="updated" /> to achieve:

tool panel labels

11 / 27

Tool Panel search configuration 1/2

The tool panel search uses a pre-built index that is compiled during Galaxy boot. You can tweak tool panel search by configuring boosts in galaxy.yml.

tool_name_boost: 9
tool_section_boost: 3
tool_description_boost: 2
tool_label_boost: 1
tool_stub_boost: 5
tool_help_boost: 0.5

You can also manipulate the number of tools returned for any query by changing the tool_search_limit. This will display more or fewer tools for any given query.

12 / 27

Tool Panel search configuration 2/2

# Enable/ disable Ngram-search for tools. It makes tool
# search results tolerant for spelling mistakes in the query
# by dividing the query into multiple ngrams and search for
# each ngram
tool_enable_ngram_search: true
# Set minimum and maximum sizes of ngrams
tool_ngram_minsize: 3
tool_ngram_maxsize: 5
13 / 27

Log level configuration

# Verbosity of console log messages.
log_level: DEBUG

These are python logging levels.

log levels

14 / 27

Help menu

# The URL linked by the "Wiki" link in the "Help" menu.
wiki_url: https://galaxyproject.org/
# The URL linked by the "Support" link in the "Help" menu.
support_url: https://galaxyproject.org/support
# The URL linked by the "How to Cite Galaxy" link in the "Help" menu.
#citation_url: https://galaxyproject.org/citing-galaxy
# The URL linked by the "Search" link in the "Help" menu.
#search_url: https://galaxyproject.org/search/
# The URL linked by the "Mailing Lists" link in the "Help" menu.
#mailing_lists_url: https://galaxyproject.org/mailing-lists
# The URL linked by the "Videos" link in the "Help" menu.
#screencasts_url: https://vimeo.com/galaxyproject
# The URL linked by the "Terms and Conditions" link in the "Help" menu, as well
# as on the user registration and login forms and in the activation emails.
#terms_url: None
15 / 27

Brand and welcome

# Append "/{brand}" to the "Galaxy" text in the masthead.
brand: GenOuest

brand

# The URL linked by the "Galaxy/brand" text.
logo_url: /
# The URL of the page to display in Galaxy's middle pane when loaded. This can
# be an absolute or relative URL.
welcome_url: /static/welcome.html
16 / 27

Email configuration

error_email_to: marten+error@bx.psu.edu
activation_email: marten+activation@bx.psu.edu
blacklist_file: config/disposable_email_blacklist.conf
registration_warning_message: Please only register one account
user_activation_on: False
activation_grace_period: 6
17 / 27

Galaxy Tours

Have their own tutorial.

18 / 27

Galaxy Webhooks

Have their own slides and tutorial.

And also a documentation

19 / 27

Adjusting styles

We use SCSS to build our CSS. Among other features it allows defining variables.

--- a/client/galaxy/style/scss/theme/blue.scss
+++ b/client/galaxy/style/scss/theme/blue.scss
@@ -2,7 +2,7 @@
-@base-color-1: #2c3143;
+@base-color-1: blue;

blue base color

20 / 27

Dynamic Welcome Page

  • Customizing the welcome page is quite easy, just edit $GALAXY_ROOT/static/welcome.html
21 / 27

Dynamic Welcome Page

  • Customizing the welcome page is quite easy, just edit $GALAXY_ROOT/static/welcome.html

  • Embedding twitter feeds is popular, e.g. usegalaxy.org

22 / 27

Dynamic Welcome Page

  • Customizing the welcome page is quite easy, just edit $GALAXY_ROOT/static/welcome.html

  • Embedding twitter feeds is popular, e.g. usegalaxy.org

  • IFrame to embed a blog hosted on the same domain

    <!-- Header -->
    <h3>News</h3>
    <!-- Iframe contents go here -->
    <div id="test-rss">
    </div>
    <!-- Load JQuery -->
    <script src="https://fqdn/galaxy/static/scripts/libs/jquery/jquery.js">
    </script>
    <!-- Load contents into div -->
    <script type="text/javascript">
    $('#test-rss').load('https://fqdn/category/dev/ #content');
    </script>
23 / 27

Toolbox filtering

# -- ToolBox filtering
# Modules from lib/galaxy/tools/toolbox/filters/ can be specified in
# the following lines. tool_* filters will be applied for all users
# and can not be changed by them. user_tool_* filters will be shown
# under user preferences and can be toggled on and off at
# runtime. Example shown below are not real defaults (no custom
# filters are applied by default), but can be enabled by renaming the
# examples.py.sample in the filters directory to examples.py.
#tool_filters =
#tool_label_filters =
#tool_section_filters =
#user_tool_filters: examples:restrict_upload_to_admins, examples:restrict_encode
#user_tool_section_filters: examples:restrict_text
#user_tool_label_filters: examples:restrict_upload_to_admins, examples:restrict_encode
# The base modules that are searched for modules as described above
# can be modified and modules external to Galaxy can be searched by
# modifying the following option.
#toolbox_filter_base_modules: galaxy.tools.toolbox.filters,galaxy.tools.filters
24 / 27

Quotas

Used to control user disk usage.

To turn on the use of quotas: In galaxy.yml:

  • enable_quotas Enable enforcement of quotas. Quotas can be set from the Admin interface (under Data).
  • must create quotas in admin interface before any quota will be enforced, otherwise 'unlimited'

Amounts:

  • Examples: "10000MB", "99 gb", "0.2T", "unlimited"
  • = / + / -

Default for user class:

  • None (No)
  • Unregistered Users
  • Registered Users

or associated with Groups or Users

25 / 27

Exercise: Creating Quotas

  • Create quotas for Unregistered (1b) and Registered Users (1mb)
  • Create a quota that adds 1GB
  • Create a quota that decreases by 1GB
  • Create a quota that grants unlimited
26 / 27

Thank You!

This material is the result of a collaborative work. Thanks to the Galaxy Training Network and all the contributors!

page logo

Tutorial Content is licensed under Creative Commons Attribution 4.0 International License.

27 / 27

Setup

We are going to use a prebuilt virtual machine image for this session.

From the given USB stick, please:

  • Copy and install VirtualBox (or download) if you do not have it already.
  • Copy the Planemo machine image - file latest.ova or download.
2 / 27
Paused

Help

Keyboard shortcuts

, , Pg Up, k Go to previous slide
, , Pg Dn, Space, j Go to next slide
Home Go to first slide
End Go to last slide
Number + Return Go to specific slide
b / m / f Toggle blackout / mirrored / fullscreen mode
c Clone slideshow
p Toggle presenter mode
t Restart the presentation timer
?, h Toggle this help
Esc Back to slideshow