forked from nickjer/singularity-rstudio
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Singularity
55 lines (45 loc) · 1.13 KB
/
Singularity
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
54
55
BootStrap: shub
From: nickjer/singularity-r
%labels
Maintainer Jeremy Nicklas
RStudio_Version 1.2.5033
%help
This will run RStudio Server
%apprun rserver
exec rserver "${@}"
%runscript
exec rserver "${@}"
%environment
export PATH=/usr/lib/rstudio-server/bin:${PATH}
%setup
install -Dv \
rstudio_auth.sh \
${SINGULARITY_ROOTFS}/usr/lib/rstudio-server/bin/rstudio_auth
install -Dv \
ldap_auth.py \
${SINGULARITY_ROOTFS}/usr/lib/rstudio-server/bin/ldap_auth
%post
# Software versions
export RSTUDIO_VERSION=1.2.5033
# Install RStudio Server
apt-get update
apt-get install -y --no-install-recommends \
ca-certificates \
wget \
gdebi-core
wget \
--no-verbose \
-O rstudio-server.deb \
"https://download2.rstudio.org/server/trusty/amd64/rstudio-server-${RSTUDIO_VERSION}-amd64.deb"
gdebi -n rstudio-server.deb
rm -f rstudio-server.deb
# Add support for LDAP authentication
wget \
--no-verbose \
-O get-pip.py \
"https://bootstrap.pypa.io/get-pip.py"
python3 get-pip.py
rm -f get-pip.py
pip3 install 'ldap3==2.9'
# Clean up
rm -rf /var/lib/apt/lists/*