Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
50 commits
Select commit Hold shift + click to select a range
0a274d7
Add mcfe workflows
OliverWoolland Sep 4, 2025
dbe016d
Add mcfe tools
OliverWoolland Sep 4, 2025
5cd9eb0
Add mcfe example data
OliverWoolland Sep 4, 2025
79c7477
Bodge readme
OliverWoolland Sep 4, 2025
14cf5fa
Add datatypes
OliverWoolland Sep 4, 2025
880fc5e
Add auth conf
OliverWoolland Sep 4, 2025
d7d086b
Add tool conf
OliverWoolland Sep 4, 2025
fad3133
Add LDAP variables to config
OliverWoolland Sep 4, 2025
2446966
Add additional ldap config
OliverWoolland Sep 4, 2025
6b6acda
Rename compose file ot new standard
OliverWoolland Sep 4, 2025
8dca878
Attempt to remove need for hard coding path
OliverWoolland Sep 4, 2025
5f0f0f5
Attempt to not need current path to be specified
OliverWoolland Sep 4, 2025
3dcca4f
Merge pull request #1 from Metaverse-Colab-for-Fusion-Energy/main
OliverWoolland Sep 4, 2025
3c815dd
Correct compose extension
OliverWoolland Sep 4, 2025
69fb889
Merge branch 'dev' of github.com:Metaverse-Colab-for-Fusion-Energy/mc…
OliverWoolland Sep 4, 2025
4c01a1a
Changing approach to path expansion
OliverWoolland Sep 4, 2025
778c55b
Correct syntax of env variable
OliverWoolland Sep 4, 2025
0275d67
Alpine blocked on RVMs
OliverWoolland Sep 4, 2025
56cd2e6
Galaxy wheels blocked
OliverWoolland Sep 4, 2025
ea52aa4
Try not to use galaxy wheels
OliverWoolland Sep 4, 2025
f7f5aa5
Pin UV
OliverWoolland Sep 4, 2025
061b2bb
Special pleading with uv
OliverWoolland Sep 4, 2025
7012f2d
Somehow needs less rum
OliverWoolland Sep 4, 2025
cc038f0
Actually do need pyproject - attempt removing lines
OliverWoolland Sep 4, 2025
0854243
No interactive prompt please
OliverWoolland Sep 4, 2025
5a16752
Patch ldap
OliverWoolland Sep 4, 2025
b4cd64e
Add mcfe tools
OliverWoolland Sep 4, 2025
aa508fb
Add ldap3 dep
OliverWoolland Sep 11, 2025
61d021c
Add ldap3 install
OliverWoolland Sep 11, 2025
3230ef8
Mispelled server name
OliverWoolland Sep 11, 2025
63b8e69
Ensure admin users is a list
OliverWoolland Sep 11, 2025
a58b858
Add remote auth, remove ldap
OliverWoolland Sep 11, 2025
e52ed47
Remove unneeded ldap patch
OliverWoolland Sep 11, 2025
76f8a35
Get rid of more ldap stuff
OliverWoolland Sep 11, 2025
7f68c10
Correct docker tool path templating
OliverWoolland Sep 11, 2025
71871c8
Make galaxy infrastructure url configurable
OliverWoolland Sep 11, 2025
cbec971
Tidy tusd config in galaxy yml
OliverWoolland Sep 11, 2025
f4cf112
Quote tus extra args
OliverWoolland Sep 11, 2025
d0cc5a1
arGGGGGs
OliverWoolland Sep 12, 2025
99b19f8
fix moose thermal simulation tool
leoxiaoyuan Sep 16, 2025
0d13526
fix tmap tool and tmap postprocessing tool
leoxiaoyuan Sep 16, 2025
fdd9d41
add moose postprocessing tool
leoxiaoyuan Sep 16, 2025
1dd4306
add moose and tmap tools to tool_conf
leoxiaoyuan Sep 16, 2025
635a2fe
add json message out to enable running next workflow earlier
leoxiaoyuan Sep 18, 2025
55081de
add upload_file_to_nucleus tool
leoxiaoyuan Sep 18, 2025
452df8a
add uid info into output message
leoxiaoyuan Sep 18, 2025
f9976c6
fix bug
leoxiaoyuan Sep 18, 2025
3c8aa2a
fix temperature attribute not found error
leoxiaoyuan Sep 24, 2025
09370cd
try to fix bug - id: cannot find name for user ID 10001
leoxiaoyuan Sep 30, 2025
c64e04b
fix tool dir cannot be found error
leoxiaoyuan Sep 30, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
45 changes: 22 additions & 23 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,30 @@
# Galaxy Show and Tell
# MCFE Galaxy

This repository serves as an example for RSEs to self host Galaxy. The repository contains a `docker-compose.yml` file that can be used to start a Galaxy instance with a few tools pre-installed.
## Triggering events

Some guides are given below to help you get started!
Randall includes services which listen for events on a MQTT broker.
These events cause further events to be triggered which may include:
- updating the metadata in Fuseki
- running workflows on Galaxy

If you are interested in some context for this repo some slides [are available](https://uomresearchit.github.io/Galaxy-Show-And-Tell/).
To see an example of this in action you can run the following command:

## Tutorials
```bash
mosquitto_pub -u {{YOUR_USER}} -P {{YOUR_PASS}} -t '/parameter/update/01234' -m '{"MajorRadius": "8.5"}
```

[Tutorial: From bootstrap to workflows! Getting started with Galaxy](docs/getting-started.md)
If you want to see the logs of the Crater service, you can do so by running:

## How to guides
```bash
mosquitto_sub -u {{YOUR_USER}} -P {{YOUR_PASS}} -t '/#' -v
```

[How to: Add tools to your Galaxy](docs/add-tools.md)
## Useful web interfaces

[How to: Add public workflows your Galaxy](docs/add-workflows.md)

## Useful resources

The best introductions to Galaxy are given by the Galaxy project itself. You may choose to start your Galaxy journey by reading the following:
[Introduction to Galaxy Analyses](https://training.galaxyproject.org/training-material/topics/introduction/)

If you are an RSE looking to develop tooling for Galaxy then generic documentation can be found at: [Developing Galaxy Tools](https://training.galaxyproject.org/training-material/topics/dev/#st-tooldev)

You could also explore the Galaxy training material for coaching Galaxy administrators, however, this is not necessary to get started and the techniques may not necessarily apply to a self-hosted instance (the Galaxy Training Network assume deployment through Ansible, we use Docker Compose).
https://training.galaxyproject.org/training-material/topics/admin/

## Technical reference

The `.env` file is self documented via the `env.template` file.
Randall is made of serveral tools which provide web interfaces. These include:
- Fuseki: http://fuseki.localhost (default username: `admin`, default password: `admin`)
* This is a triplestore which stores the metadata
- Galaxy: http://galaxy.localhost (username and password from .env file)
* This is a workflow manager which runs workflows
- Traefik: http://localhost:8888 (no authentication)
* This is a reverse proxy which routes traffic to the appropriate service
15 changes: 9 additions & 6 deletions docker-compose.yml → compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,11 @@ services:
USER root
RUN apt update && apt -y install docker.io
USER galaxy
COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/
COPY --from=ghcr.io/astral-sh/uv:0.8.15 /uv /uvx /bin/
ENV HOME=/tmp
ENV UV_CACHE=/tmp/uv_cache
RUN uv add boto3
RUN sed -i '/wheels.galaxyproject.org/d' pyproject.toml
RUN uv add boto3 --index https://pypi.org/simple
restart: unless-stopped
group_add:
- ${DOCKER_GID}
Expand All @@ -49,8 +50,9 @@ services:
- ./galaxy/tusd:/usr/local/sbin/tusd
# Populate the instance
- ./galaxy/tools:/galaxy/server/tools/
- ./galaxy/lib/mcfe_datatypes.py:/galaxy/server/lib/galaxy/datatypes/mcfe_datatypes.py
# Add custom configuration files
- ./galaxy/config/tool_conf.xml:/galaxy/server/config/tool_conf.xml.sample
- ./galaxy/config/tool_conf.xml:/galaxy/server/config/tool_conf.xml
- ./galaxy/config/datatypes_conf.xml:/galaxy/server/config/datatypes_conf.xml
# Provide docker-in-docker
- /var/run/docker.sock:/var/run/docker.sock:ro
Expand Down Expand Up @@ -86,11 +88,13 @@ services:
build:
context: .
dockerfile_inline: |
FROM alpine:3.22
RUN apk update && apk add gettext bash
FROM ubuntu:22.04
RUN apt update && apt install -y gettext
COPY ./galaxy/init/template.sh /template.sh
container_name: ${PROJECT_NAME}-galaxy-template-eval
env_file: .env
environment:
REPO_PATH: ${PWD}
volumes:
- ./galaxy/config/:/work
- galaxy-store:/galaxy/server/
Expand Down Expand Up @@ -146,7 +150,6 @@ services:
minio:
condition: service_healthy
volumes:
- ./minio/init/bootstrap.sh:/bootstrap.sh
- ./minio/data:/data:ro
networks:
- galaxy
Expand Down
6 changes: 2 additions & 4 deletions env.template
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@
# ------------------------------------------------------------------------------
# Parameters to configure the Galaxy instance

# The path to this repo
REPO_PATH=/home/owool/Projects/2025/RSE-Galaxy

# The group ID of the docker group on the host machine, to allow the Galaxy
# container to access the docker socket.

Expand All @@ -23,7 +20,8 @@ GALAXY_ADMIN_PASS={{adminadmin}}
GALAXY_API_KEY={{iamanadminyouknow}}

# Galaxy config
GALAXY_VERSION=25.0.2
GALAXY_VERSION={{25.0.2}}
GALAXY_URL={{https://mygalaxy.org}}

# ------------------------------------------------------------------------------
# General configuration parameters
Expand Down
4 changes: 4 additions & 0 deletions galaxy/config/datatypes_conf.xml
Original file line number Diff line number Diff line change
Expand Up @@ -694,6 +694,10 @@
<datatype extension="oxligl" type="galaxy.datatypes.binary:OxliGraphLabels" mimetype="application/octet-stream" display_in_upload="true"/>
<!-- Constructive solid geometry datatypes -->
<datatype extension="stl" type="galaxy.datatypes.constructive_solid_geometry:STL" display_in_upload="true"/>
<datatype extension="vtu" type="galaxy.datatypes.mcfe_datatypes:vtu" display_in_upload="true" />
<datatype extension="pvtu" type="galaxy.datatypes.mcfe_datatypes:pvtu" display_in_upload="true"/>
<datatype extension="vtp" type="galaxy.datatypes.mcfe_datatypes:vtp" display_in_upload="true"/>

<datatype extension="plyascii" type="galaxy.datatypes.constructive_solid_geometry:PlyAscii" display_in_upload="true"/>
<datatype extension="plybinary" type="galaxy.datatypes.constructive_solid_geometry:PlyBinary" display_in_upload="true"/>
<datatype extension="vtkascii" type="galaxy.datatypes.constructive_solid_geometry:VtkAscii" display_in_upload="true"/>
Expand Down
17 changes: 9 additions & 8 deletions galaxy/config/galaxy.yml.template
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,16 @@ gravity:
gunicorn:
bind: 0.0.0.0:8080
workers: 2
extra_ars: '--forwarded-allow-ips="*"'
extra_args: '--forwarded-allow-ips="*"'
preload: true
celery:
concurrency: 2
loglevel: WARNING
tusd:
enable: true
host: 0.0.0.0
port: 1080
tusd_path: /usr/local/sbin/tusd
upload_dir: /galaxy/server/data/tus/
extra_args: '-verbose'
# handlers:
# handler:
# processes: 2
Expand All @@ -28,12 +27,15 @@ gravity:

galaxy:
# Main config
admin_users:
- admin@example.org
admin_users: admin@example.org
bootstrap_admin_api_key: '$GALAXY_API_KEY'
id_secret: 'morestufftoreplace'
log_level: WARNING

# Use remote users
use_remote_user: true
remote_user_maildomain: example.org

# Watch file changes
watch_tools: 'true'
watch_job_rules: 'true'
Expand Down Expand Up @@ -61,7 +63,7 @@ galaxy:
new_user_dataset_access_role_default_private: true

# TUS
galaxy_infrastructure_url: "http://localhost:8080"
galaxy_infrastructure_url: "$GALAXY_URL"
tus_upload_store: /galaxy/server/data/tus/

# SQL Performance
Expand All @@ -75,7 +77,6 @@ galaxy:
retry_job_output_collection: 3

# Debugging
cleanup_job: onsuccess
allow_user_impersonation: true

# Object Store
Expand Down Expand Up @@ -117,7 +118,7 @@ galaxy:
shed_data_manager_config_file: /galaxy/server/config/shed_data_manager_conf.xml
shed_tool_config_file: /galaxy/server/config/shed_tool_conf.xml
shed_tool_data_table_config: /galaxy/server/config/shed_tool_data_table_conf.xml
tool_config_file: /galaxy/server/config/tool_conf.xml.sample
tool_config_file: /galaxy/server/config/tool_conf.xml
job_config_file: /galaxy/server/config/job_conf.xml
tool_data_path: /galaxy/server/database/tool_data
tool_data_table_config_path: /galaxy/server/config/tool_data_table_conf.xml.sample
Expand Down
9 changes: 7 additions & 2 deletions galaxy/config/job_conf.xml.template
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,16 @@
</destination>
<destination id="docker_root" runner="local">
<param id="docker_enabled">true</param>
<param id="docker_volumes">galaxy-store:/galaxy/server</param>
<param id="docker_sudo">true</param>
<param id="docker_volumes">galaxy-store:/galaxy/server,$REPO_PATH/galaxy/tools:/galaxy/server/tools</param>
<param id="docker_sudo">false</param>
<param id="docker_set_user">0</param>
<param id="docker_auto_rm">true</param>
<param id="docker_run_extra_arguments">--entrypoint '' --env PATH=/opt/openmpi/bin:/opt/rh/gcc-toolset-12/root/usr/bin:$PATH </param>

</destination>
</destinations>
<tools>
<tool id="tmap8" destination="docker_root" />
<tool id="moose" destination="docker_root" />
</tools>
</job_conf>
76 changes: 76 additions & 0 deletions galaxy/config/tool_conf.xml
Original file line number Diff line number Diff line change
Expand Up @@ -60,4 +60,80 @@
<tool file="plotting/boxplot.xml" hidden="true" />
<tool file="maf/vcf_to_maf_customtrack.xml" />
</section>
<section id="MCFE_OpenMC" name="MCFE OpenMC Tools">
<tool file="openmc/openmc.xml" />
</section>
<section id="MCFE_CAD_Converters" name="MCFE CAD Converters">
<tool file="USD_to_h5m/USD_to_h5m.xml" />
<tool file="h5m_to_vtk/h5m_to_vtk.xml" />
<tool file="obj_to_USD/obj_to_USD.xml" />
<tool file="vtp_to_obj/vtp_to_obj.xml" />
<tool file="stp_to_stl/stp_to_stl.xml" />
<tool file="stl_to_h5m/stl_to_h5m.xml" />
<tool file="h5m_to_stl/h5m_to_stl.xml" />
<tool file="stl_to_obj/stl_to_obj.xml" />
<tool file="tracks_to_vtp/tracks_to_vtp.xml" />
</section>
<section id="MCFE_Other_Converters" name="MCFE Converter Tools">
<tool file="normalise_tallies/normalise_tallies.xml" />
<tool file="h5m_materials/h5m_materials.xml" />
<tool file="flatten_USD/flatten_USD.xml" />
<tool file="extract_openmc_tallies/extract_openmc_tallies.xml" />
<tool file="json_string_to_file/json_string_to_file.xml" />
<tool file="json_file_to_string/json_file_to_string.xml" />
</section>
<section id="MCFE_Parametric_Tools" name="MCFE Parametric Tools">
<tool file="capella_paramak_generator/capella_paramak_generator.xml" />
<tool file="capella_openmc/capella_openmc.xml" />
</section>
<section id="MCFE_PINN_Tools" name="MCFE PINN Tools">
<tool file="heatflux_to_PINN/heatflux_to_PINN.xml" />
<tool file="paramak_to_PINN/paramak_to_PINN.xml" />
<tool file="sample_points_PINN/sample_points_PINN.xml" />
<tool file="visualisation_PINN/visualisation_PINN.xml" />
<tool file="modulus/modulus.xml" />
</section>
<section id="MCFE_Data" name="MCFE Data">
<tool file="minio_push/minio_push.xml" />
<tool file="minio_pull/minio_pull.xml" />
</section>
<section id="MCFE_Unstructured_Mesh_Tools" name="MCFE Unstructured Mesh Tools">
<tool file="unstructured_convert_heating/unstructured_convert_heating.xml" />
<tool file="unstructured_mesh_openmc/unstructured_mesh_openmc.xml" />
<tool file="unstructured_heatflux_to_PINN/unstructured_heatflux_to_PINN.xml" />
</section>
<section id="MCFE_Misc" name="MCFE Misc Tools">
<tool file="save-output-rocrate/save_output_rocrate.xml" />
<tool file="tile_paramak/tile_paramak.xml" />
<tool file="tile_openmc/tile_openmc.xml" />
<tool file="trained_PINN/trained_PINN.xml" />
<tool file="MQTT_pub/MQTT_pub.xml" />
</section>
<section id="MCFE_Deprecated" name="MCFE Deprecated Tools">
<tool file="paramak_generator/paramak_generator.xml" />
<tool file="openmc_parametric/openmc_parametric.xml" />
<tool file="paramak_generator_noplasma/paramak_generator_noplasma.xml" />
</section>
<section id="nTtau_Tools" name="nTtau Digital Tools">
<tool file="containment_vessel/containment_vessel.xml" />
<tool file="cylinder_gen/cylinder_gen.xml" />
<tool file="CylinderBCMesh/CylinderBCMesh.xml" />
<tool file="get_bounding_box/get_bounding_box.xml" />
<tool file="sphere_gen/sphere_gen.xml" />
<tool file="sphereBCMesh/sphereBCMesh.xml" />
<tool file="step_to_vtk/step_to_vtk.xml" />
<tool file="tokamak_gen/tokamak_gen.xml" />
</section>
<section id="LIBRTI_Tools" name="LIBRTI Tools">
<tool file="moose/moose.xml" />
<tool file="tmap8/tmap8.xml" />
<tool file="moose_postprocess/moose_postprocess.xml" />
<tool file="tmap_postprocess/tmap_postprocess.xml" />
<tool file="create_sample_msh/create_sample_msh.xml" />
<tool file="tmap_extract_flow/tmap_extract_flow.xml" />
<tool file="upload_file_to_nucleus/upload_file_to_nucleus.xml" />
</section>
<section id="Test" name="Test Tools">
<tool file="test.xml" />
</section>
</toolbox>
74 changes: 74 additions & 0 deletions galaxy/lib/mcfe_datatypes.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
"""
Classes for MCFE added datatypes
"""

from galaxy.datatypes import data
from galaxy.datatypes.metadata import MetadataElement

import os
import logging

log = logging.getLogger(__name__)

class vtp(data.Data):
file_ext = "vtp"

class vtk(data.Data):
file_ext = "vtk"

class vtu(data.Data):
file_ext = "vtu"

class pvtu(data.Data):
file_ext = "pvtu"

class usd(data.Data):
file_ext = "usd"

class usda(data.Data):
file_ext = "udsa"

class usdc(data.Data):
file_ext = "usdc"

class usdz(data.Data):
file_ext = "usdz"

class obj(data.Data):
file_ext = "obj"

class stp(data.Data):
file_ext = "stp"

class step(data.Data):
file_ext = "step"

class h5(data.Data):
file_ext = "h5"

class h5m(data.Data):
file_ext = "h5m"

class out(data.Data):
file_ext = "out"

class xml(data.Data):
file_ext = "xml"

class stl(data.Data):
file_ext = "stl"

class npz(data.Data):
file_ext = "npz"

class yaml(data.Data):
file_ext = "yaml"

class odb(data.Data):
file_ext = "odb"

class inp(data.Data):
file_ext = "inp"

class pth(data.Data):
file_ext = "pth"
Loading