This repository has been archived by the owner on Jun 6, 2024. It is now read-only.
forked from cernphsft/rootbinder
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
53 lines (41 loc) · 1.46 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
FROM andrewosh/binder-base
MAINTAINER Enric Tejedor Saavedra <[email protected]>
USER root
# Install ROOT prerequisites
RUN apt-get update
RUN apt-get install -y \
libx11-6 \
libxext6 \
libxft2 \
libxpm4
# Install ROOT additional libraries
RUN apt-get install -y \
r-base \
r-base-dev
# Install R packages
RUN R -e "install.packages(c('Rcpp','RInside'), repos = \"http://cran.case.edu\")"
# Download and install ROOT master
WORKDIR /opt
RUN wget http://root.cern.ch/notebooks/rootbinderdata/root.tar.gz
RUN tar xzf root.tar.gz
RUN rm root.tar.gz
# Download and install Fastjet
RUN wget http://root.cern.ch/notebooks/rootbinderdata/fastjet.tar.gz
RUN tar xzf fastjet.tar.gz
RUN rm fastjet.tar.gz
USER main
# Set ROOT environment
ENV ROOTSYS "/opt/root"
ENV PATH "$ROOTSYS/bin:$ROOTSYS/bin/bin:$PATH"
ENV LD_LIBRARY_PATH "$ROOTSYS/lib:$LD_LIBRARY_PATH"
ENV PYTHONPATH "$ROOTSYS/lib:PYTHONPATH"
# Set ROOT environment for Fastjet
ENV LD_LIBRARY_PATH "/opt/fastjet/lib:$LD_LIBRARY_PATH"
ENV ROOT_INCLUDE_PATH "/opt/fastjet/include"
# Customise the ROOTbook
RUN pip install --upgrade pip
RUN pip install metakernel
RUN mkdir -p $HOME/.ipython/kernels
RUN cp -r $ROOTSYS/etc/notebook/kernels/root $HOME/.ipython/kernels
RUN mkdir -p $HOME/.ipython/profile_default/static
RUN cp -r $ROOTSYS/etc/notebook/custom $HOME/.ipython/profile_default/static