Giter Site home page Giter Site logo

georgysk / jupyterlab-extension Goto Github PK

View Code? Open in Web Editor NEW

This project forked from rucio/jupyterlab-extension

0.0 0.0 0.0 1.52 MB

Rucio Jupyterlab plugin (GSOC Project)

License: Apache License 2.0

Shell 0.59% JavaScript 0.18% Python 47.14% TypeScript 51.58% CSS 0.26% Dockerfile 0.25%

jupyterlab-extension's Introduction

Rucio JupyterLab Extension

Test Build and Publish Extension

This is a JupyterLab extension that integrates with Rucio - Scientific Data Management to allow users to access some of Rucio's capabilities directly from the JupyterLab interface.

This extension is composed of a Python package named rucio_jupyterlab for the server extension and a NPM package named rucio-jupyterlab for the frontend extension.

Requirements

  • JupyterLab >= 3.0
  • Rucio Server >= 1.28

Install

You will need NodeJS to install the extension. For JupyterLab 4.x you will need NodeJS>=v20 and >=v14 for JupyterLab 3.x.

JupyterLab 4.x

pip install rucio-jupyterlab

JupyterLab 3.x

For JupyterLab 3.x, please use the last supported version.

pip install rucio-jupyterlab==0.9.10

Download mode

If you are going to run the extension in Download mode, you will also need to install libraries required by the RSE downloaders. For instance, gfal2, which is available in EPEL or conda-forge.

Additionally, you need to have grid-proxy-init or voms-proxy-init executable. You can do so by installing voms-clients-java.

$ apt install voms-clients-java
$ conda install -c conda-forge python-gfal2
# OR
$ yum install epel-release
$ yum install gfal2-all gfal2-python voms-clients-java

To be able to access the paths from within the notebook, you need to add the following snippet in your IPython configuration (e.g. ~/.ipython/profile_default/ipython_kernel_config.py).

c.IPKernelApp.extensions = ['rucio_jupyterlab.kernels.ipython']

More details in the IPython Kernel configuration

Restart your JupyterLab instance afterwards to load the server extension.

Configuration

See CONFIGURATION.md

Contributing

If you want to contribute or build the extension from source, see CONTRIBUTING.md

Quick Setup using Docker

This repository comes with a Docker image of jupyter/scipy-notebook installed with the extension.

To run the image, use the following command.

Replica Mode

$ docker run -d -p 8888:8888 \
    -e RUCIO_MODE=replica \
    -e RUCIO_WILDCARD_ENABLED=<true = 1, false = 0> \
    -e RUCIO_BASE_URL=<Rucio base URL> \
    -e RUCIO_AUTH_URL=<Rucio auth URL (if any)> \
    -e RUCIO_DESTINATION_RSE=<destination RSE> \
    -e RUCIO_DISPLAY_NAME=<instance display name> \
    -e RUCIO_NAME=<instance name> \
    -e RUCIO_SITE_NAME=ROAMING \
    -e RUCIO_VO=def \
    -e RUCIO_PATH_BEGINS_AT=<path begins at> \
    -e RUCIO_RSE_MOUNT_PATH=<mount path> \
    -v <host folder>:<container folder> \
    rucio/jupyterlab:latest

<host folder> is a folder in the host that is mounted to a Rucio Storage Element via FUSE. <container folder> is a folder accessible from the notebook that is mounted to the host folder.

Download Mode

$ docker run -d -p 8888:8888 \
    -e RUCIO_MODE=download \
    -e RUCIO_WILDCARD_ENABLED=<true = 1, false = 0> \
    -e RUCIO_BASE_URL=<Rucio base URL> \
    -e RUCIO_AUTH_URL=<Rucio auth URL (if any)> \
    -e RUCIO_DISPLAY_NAME=<instance display name> \
    -e RUCIO_NAME=<instance name> \
    -e RUCIO_SITE_NAME=ROAMING \
    -e RUCIO_VO=def \
    -e RUCIO_VOMS_ENABLED=<true = 1, false = 0> \
    -e RUCIO_VOMS_VOMSES_PATH=<path to vomses file (optional)> \
    -e RUCIO_VOMS_CERTDIR_PATH=<path to certdir (optional)> \
    -e RUCIO_VOMS_VOMSDIR_PATH=<path to vomsdir (optional)> \
    -e RUCIO_CA_CERT=/certs/rucio_ca.pem \
    -v <path to Rucio CA PEM file>:/certs/rucio_ca.pem \
    rucio/jupyterlab:latest

Follow the configuration guide for details of the parameters.

Troubleshoot

If you are seeing the frontend extension but it is not working, check that the server extension is enabled:

jupyter serverextension list

If the server extension is installed and enabled but you are not seeing the frontend, check the frontend is installed:

jupyter labextension list

If it is installed, try:

jupyter lab clean
jupyter lab build

jupyterlab-extension's People

Contributors

didithilmy avatar garciagenrique avatar soap2g avatar bari12 avatar albavemo avatar egazzarr avatar goseind avatar ftorradeflot avatar mlassnig avatar dependabot[bot] avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.