forked from yjin4-at-uofh/Dockerfiles
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
70 lines (59 loc) · 2.36 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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
#
# XUbuntu Desktop self-loaded Dockerfile
#
# BASE_IMAGE
# Pull base image.
ARG BASE_IMAGE=nvcr.io/nvidia/cuda:11.5.0-runtime-ubuntu20.04
FROM $BASE_IMAGE
LABEL maintainer="Yuchen Jin <[email protected]>" \
author="Yuchen Jin <[email protected]>" \
description="xUbuntu desktop dockerfile for ubuntu 16.04, 18.04 and 20.04 images." \
version="1.7" \
modifiedby="Pratik Mehta"
ARG BASE_LAUNCH=/opt/nvidia/nvidia_entrypoint.sh
# Since 22.03 ?: /opt/nvidia/nvidia_entrypoint.sh
# Before: /usr/local/bin/nvidia_entrypoint.sh
ARG JLAB_VER=unset
ARG JLAB_EXTIERS=2
ARG WITH_CHINESE="false"
ARG WITH_EXTRA_APPS=""
ARG ADDR_PROXY=unset
ARG DEBIAN_FRONTEND=noninteractive
ENV USER="root" MKL_CBWR="AUTO" LAUNCH_SCRIPT_ORIGINAL="$BASE_LAUNCH" PATH="${PATH}:/usr/games"
# Move configs.
COPY configs /root/docker-configs
RUN chmod +x /root/docker-configs/ --recursive && bash /root/docker-configs/detach MODE=basic
ENV LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 LANGUAGE=en_US.UTF-8
# Install prepared packages
COPY scripts/install-base /root/scripts/
RUN chmod +x /root/scripts/install-base && bash /root/scripts/install-base MODE=init
# Install xfce4 Desktop
COPY scripts/install-desktop* /root/scripts/
RUN chmod +x /root/scripts/install-desktop && chmod +x /root/scripts/install-desktop-exts && bash /root/scripts/install-desktop MODE=desktop
RUN /etc/init.d/dbus start
RUN bash /root/scripts/install-base MODE=check
# Install extra packages
RUN bash /root/scripts/install-desktop MODE=apps JLAB_VER=${JLAB_VER} JLAB_EXTIERS=${JLAB_EXTIERS}
# The following step is not stable, so we move it here. -removed most stuff - pmehta
RUN bash /root/docker-configs/detach MODE=shortcuts
# Install modern vncserver and themes
COPY scripts/install-vnc /root/scripts/
RUN bash /root/scripts/install-vnc MODE=vnc
RUN bash /root/scripts/install-vnc MODE=theme
# Define working directory.
RUN bash /root/docker-configs/detach MODE=clean
COPY entrypoints/ /usr/local/bin/
RUN chmod +x /usr/local/bin/docker-entrypoint && chmod +x /usr/local/bin/user-mapping && chmod +x /usr/local/bin/xvnc-launch && chmod +x /usr/local/bin/set-bing-wallpaper && chmod +x /usr/local/bin/yjin-tool
# Expose the built-in ports.
EXPOSE 5212
EXPOSE 5901
EXPOSE 6080
EXPOSE 5555
EXPOSE 4444
EXPOSE 3333
# Define default command.
USER xubuntu
ENV USER="xubuntu"
WORKDIR /home/xubuntu
ENTRYPOINT ["bash", "docker-entrypoint"]
CMD [""]