Dockerfile 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605
  1. # syntax=docker/dockerfile:1.7
  2. # Final target:
  3. # Ubuntu 24.04 + NVIDIA GLX + XFCE + PipeWire + Firefox + Selkies
  4. #
  5. # The build uses intermediate stages, but produces a single final image.
  6. ARG DISTRIB_RELEASE=24.04
  7. ARG SELKIES_IMAGE=ghcr.io/selkies-project/selkies/py-build:main
  8. ARG SELKIES_GIT_REF=main
  9. ARG NVIDIA_VAAPI_DRIVER_VERSION=latest
  10. # -----------------------------------------------------------------------------
  11. # Current Selkies wheel
  12. # -----------------------------------------------------------------------------
  13. FROM ${SELKIES_IMAGE} AS selkies-build
  14. # -----------------------------------------------------------------------------
  15. # Selkies joystick interposer
  16. # -----------------------------------------------------------------------------
  17. # Build the Selkies joystick interposer directly from its official source.
  18. FROM docker.io/library/ubuntu:${DISTRIB_RELEASE} AS selkies-js-interposer-builder
  19. ARG DEBIAN_FRONTEND=noninteractive
  20. ARG SELKIES_GIT_REF
  21. SHELL ["/bin/bash", "-o", "pipefail", "-c"]
  22. RUN apt-get update \
  23. && apt-get install --no-install-recommends -y \
  24. build-essential \
  25. ca-certificates \
  26. curl \
  27. && rm -rf /var/lib/apt/lists/*
  28. RUN set -eux; \
  29. curl -fsSL \
  30. "https://raw.githubusercontent.com/selkies-project/selkies/${SELKIES_GIT_REF}/addons/js-interposer/joystick_interposer.c" \
  31. -o /tmp/joystick_interposer.c; \
  32. install -d -m 0755 /out; \
  33. gcc -shared -fPIC -O2 \
  34. -Wl,-z,relro,-z,now \
  35. -o /out/selkies_joystick_interposer.so \
  36. /tmp/joystick_interposer.c \
  37. -ldl; \
  38. test -s /out/selkies_joystick_interposer.so
  39. # -----------------------------------------------------------------------------
  40. # Build the Selkies Python environment
  41. # -----------------------------------------------------------------------------
  42. FROM docker.io/library/ubuntu:${DISTRIB_RELEASE} AS selkies-runtime-builder
  43. ARG DEBIAN_FRONTEND=noninteractive
  44. SHELL ["/bin/bash", "-o", "pipefail", "-c"]
  45. COPY --from=selkies-build /opt/pypi/dist/selkies-*.whl /tmp/
  46. RUN apt-get update \
  47. && apt-get install --no-install-recommends -y \
  48. build-essential \
  49. libsm6 \
  50. libopus0 \
  51. libpulse0 \
  52. libxkbcommon-dev \
  53. pkg-config \
  54. python3 \
  55. python3-dev \
  56. python3-pip \
  57. python3-venv \
  58. && python3 -m venv /opt/selkies \
  59. && /opt/selkies/bin/python -m pip install \
  60. --no-cache-dir \
  61. --upgrade \
  62. pip \
  63. setuptools \
  64. wheel \
  65. && printf '%s\n' \
  66. 'pixelflux==1.6.4' \
  67. 'pcmflux==1.0.8' \
  68. > /tmp/selkies-constraints.txt \
  69. && /opt/selkies/bin/python -m pip install \
  70. --no-cache-dir \
  71. --force-reinstall \
  72. --constraint /tmp/selkies-constraints.txt \
  73. /tmp/selkies-*.whl
  74. # -----------------------------------------------------------------------------
  75. # Build the current nvidia-vaapi-driver without retaining build dependencies
  76. # -----------------------------------------------------------------------------
  77. FROM docker.io/library/ubuntu:${DISTRIB_RELEASE} AS nvidia-vaapi-builder
  78. ARG DEBIAN_FRONTEND=noninteractive
  79. ARG NVIDIA_VAAPI_DRIVER_VERSION
  80. SHELL ["/bin/bash", "-o", "pipefail", "-c"]
  81. RUN apt-get update \
  82. && apt-get install --no-install-recommends -y \
  83. ca-certificates \
  84. curl \
  85. gcc \
  86. jq \
  87. meson \
  88. ninja-build \
  89. pkg-config \
  90. libdrm-dev \
  91. libegl-dev \
  92. libffmpeg-nvenc-dev \
  93. libgstreamer-plugins-bad1.0-dev \
  94. libva-dev \
  95. && rm -rf /var/lib/apt/lists/*
  96. RUN set -eux; \
  97. version="${NVIDIA_VAAPI_DRIVER_VERSION}"; \
  98. if [[ "${version}" == "latest" ]]; then \
  99. version="$(curl -fsSL https://api.github.com/repos/elFarto/nvidia-vaapi-driver/releases/latest \
  100. | jq -r '.tag_name' \
  101. | sed 's/^v//')"; \
  102. fi; \
  103. curl -fsSL \
  104. "https://github.com/elFarto/nvidia-vaapi-driver/archive/refs/tags/v${version}.tar.gz" \
  105. -o /tmp/nvidia-vaapi-driver.tar.gz; \
  106. mkdir -p /tmp/nvidia-vaapi-driver; \
  107. tar -xzf /tmp/nvidia-vaapi-driver.tar.gz \
  108. --strip-components=1 \
  109. -C /tmp/nvidia-vaapi-driver; \
  110. cd /tmp/nvidia-vaapi-driver; \
  111. meson setup build \
  112. --prefix=/usr \
  113. --buildtype=release; \
  114. meson compile -C build; \
  115. DESTDIR=/out meson install -C build
  116. # -----------------------------------------------------------------------------
  117. # Build the Selkies web frontend from the official source repository
  118. # -----------------------------------------------------------------------------
  119. FROM docker.io/library/node:22-bookworm-slim AS selkies-web-builder
  120. ARG DEBIAN_FRONTEND=noninteractive
  121. ARG SELKIES_GIT_REF=main
  122. ARG SELKIES_MODE=websockets
  123. ARG SELKIES_UPLOAD_DIR=/home/ubuntu/Desktop
  124. SHELL ["/bin/bash", "-o", "pipefail", "-c"]
  125. RUN apt-get update \
  126. && apt-get install --no-install-recommends -y \
  127. ca-certificates \
  128. cmake \
  129. curl \
  130. git \
  131. && rm -rf /var/lib/apt/lists/*
  132. WORKDIR /tmp/selkies
  133. RUN curl -fsSL \
  134. "https://github.com/selkies-project/selkies/archive/${SELKIES_GIT_REF}.tar.gz" \
  135. -o /tmp/selkies.tar.gz \
  136. && tar -xzf /tmp/selkies.tar.gz \
  137. --strip-components=1 \
  138. -C /tmp/selkies \
  139. && rm -f /tmp/selkies.tar.gz
  140. RUN set -eux; \
  141. cd /tmp/selkies/addons/selkies-web-core; \
  142. npm install; \
  143. npm run build; \
  144. \
  145. cd /tmp/selkies/addons/selkies-dashboard; \
  146. cp ../selkies-web-core/dist/selkies-core.js src/; \
  147. npm install; \
  148. SELKIES_INJECT=1 \
  149. SELKIES_MODE="${SELKIES_MODE}" \
  150. SELKIES_UPLOAD_DIR="${SELKIES_UPLOAD_DIR}" \
  151. npm run build; \
  152. \
  153. mkdir -p dist/src; \
  154. cp ../selkies-web-core/dist/selkies-core.js dist/src/; \
  155. cp ../universal-touch-gamepad/universalTouchGamepad.js dist/src/; \
  156. cp -r ../selkies-web-core/dist/jsdb dist/; \
  157. \
  158. mkdir -p /out; \
  159. cp -a dist/. /out/; \
  160. test -f /out/index.html
  161. # -----------------------------------------------------------------------------
  162. # Final image
  163. # -----------------------------------------------------------------------------
  164. FROM docker.io/library/ubuntu:${DISTRIB_RELEASE}
  165. ARG DEBIAN_FRONTEND=noninteractive
  166. ARG DISTRIB_RELEASE
  167. ARG TZ=UTC
  168. ARG USER_NAME=ubuntu
  169. ARG USER_UID=1000
  170. ARG USER_GID=1000
  171. LABEL org.opencontainers.image.title="Selkies NVIDIA XFCE Desktop" \
  172. org.opencontainers.image.description="XFCE remote desktop with Selkies, PipeWire and NVIDIA acceleration" \
  173. org.opencontainers.image.source="https://github.com/selkies-project/selkies"
  174. SHELL ["/bin/bash", "-o", "pipefail", "-c"]
  175. ENV TZ="${TZ}" \
  176. LANG="en_US.UTF-8" \
  177. LANGUAGE="en_US:en" \
  178. LC_ALL="en_US.UTF-8" \
  179. PASSWD="mypasswd" \
  180. DISPLAY=":20" \
  181. DISPLAY_SIZEW="1920" \
  182. DISPLAY_SIZEH="1080" \
  183. DISPLAY_REFRESH="60" \
  184. DISPLAY_DPI="96" \
  185. DISPLAY_CDEPTH="24" \
  186. VIDEO_PORT="DFP" \
  187. DESKTOP_SESSION="xfce" \
  188. XDG_SESSION_DESKTOP="xfce" \
  189. XDG_CURRENT_DESKTOP="XFCE" \
  190. XDG_SESSION_TYPE="x11" \
  191. SELKIES_MODE="websockets" \
  192. SELKIES_PORT="8081" \
  193. SELKIES_ENCODER="h264enc" \
  194. SELKIES_ENABLE_RESIZE="false" \
  195. SELKIES_ENABLE_BASIC_AUTH="true" \
  196. NVIDIA_VISIBLE_DEVICES="all" \
  197. NVIDIA_DRIVER_CAPABILITIES="all" \
  198. __GL_SYNC_TO_VBLANK="0" \
  199. __GLX_VENDOR_LIBRARY_NAME="nvidia" \
  200. LIBVA_DRIVER_NAME="nvidia" \
  201. NVD_BACKEND="direct" \
  202. MOZ_DISABLE_RDD_SANDBOX="1" \
  203. MOZ_X11_EGL="1" \
  204. PIPEWIRE_LATENCY="128/48000" \
  205. XDG_RUNTIME_DIR="/tmp/runtime-ubuntu" \
  206. PIPEWIRE_RUNTIME_DIR="/tmp/runtime-ubuntu" \
  207. PULSE_RUNTIME_PATH="/tmp/runtime-ubuntu/pulse" \
  208. PULSE_SERVER="unix:/tmp/runtime-ubuntu/pulse/native" \
  209. DBUS_SYSTEM_BUS_ADDRESS="unix:path=/tmp/runtime-ubuntu/dbus-system-bus" \
  210. APPIMAGE_EXTRACT_AND_RUN="1" \
  211. SUDO_EDITOR="mousepad"
  212. # Bootstrap packages needed to configure APT repositories.
  213. RUN apt-get update \
  214. && apt-get install --no-install-recommends -y \
  215. ca-certificates \
  216. curl \
  217. gnupg \
  218. locales \
  219. ssl-cert \
  220. tzdata \
  221. && locale-gen en_US.UTF-8 fr_FR.UTF-8 \
  222. && ln -snf "/usr/share/zoneinfo/${TZ}" /etc/localtime \
  223. && echo "${TZ}" > /etc/timezone \
  224. && rm -rf /var/lib/apt/lists/*
  225. # Keep the same Mozilla and PipeWire repositories as the original image.
  226. RUN install -d -m 0755 \
  227. /etc/apt/preferences.d \
  228. /etc/apt/sources.list.d \
  229. /etc/apt/trusted.gpg.d \
  230. && printf '%s\n' \
  231. 'Package: firefox*' \
  232. 'Pin: version 1:1snap*' \
  233. 'Pin-Priority: -1' \
  234. > /etc/apt/preferences.d/firefox-nosnap \
  235. && curl -fsSL \
  236. 'https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x738BEB9321D1AAEC13EA9391AEBDF4819BE21867' \
  237. | gpg --dearmor \
  238. > /etc/apt/trusted.gpg.d/mozillateam-ubuntu-ppa.gpg \
  239. && echo \
  240. "deb https://ppa.launchpadcontent.net/mozillateam/ppa/ubuntu noble main" \
  241. > /etc/apt/sources.list.d/mozillateam-ubuntu-ppa.list \
  242. && curl -fsSL \
  243. 'https://keyserver.ubuntu.com/pks/lookup?op=get&search=0xFC43B7352BCC0EC8AF2EEB8B25088A0359807596' \
  244. | gpg --dearmor \
  245. > /etc/apt/trusted.gpg.d/pipewire-debian-ubuntu.gpg \
  246. && echo \
  247. "deb https://ppa.launchpadcontent.net/pipewire-debian/pipewire-upstream/ubuntu noble main" \
  248. > /etc/apt/sources.list.d/pipewire-upstream.list \
  249. && echo \
  250. "deb https://ppa.launchpadcontent.net/pipewire-debian/wireplumber-upstream/ubuntu noble main" \
  251. > /etc/apt/sources.list.d/wireplumber-upstream.list
  252. # Base system, desktop, Xorg, NVIDIA runtime interfaces and user tools.
  253. # There are deliberately no Intel/AMD VA-API or Vulkan drivers and no i386
  254. # architecture.
  255. RUN apt-get update \
  256. && apt-get install --no-install-recommends -y \
  257. apt-utils \
  258. bash-completion \
  259. binutils \
  260. btop \
  261. bzip2 \
  262. clinfo \
  263. dbus-user-session \
  264. dbus-x11 \
  265. desktop-file-utils \
  266. dnsutils \
  267. file \
  268. firefox \
  269. fonts-dejavu \
  270. fonts-liberation \
  271. fonts-noto \
  272. fonts-noto-cjk \
  273. fonts-noto-color-emoji \
  274. fonts-noto-mono \
  275. fonts-ubuntu \
  276. fuse \
  277. git \
  278. gvfs \
  279. jq \
  280. kmod \
  281. less \
  282. libdrm2 \
  283. libegl1 \
  284. libelf-dev \
  285. libgcrypt20 \
  286. libgl1 \
  287. libgles1 \
  288. libgles2 \
  289. libglu1-mesa \
  290. libglvnd-dev \
  291. libglvnd0 \
  292. libglx0 \
  293. libgstreamer-plugins-bad1.0-0 \
  294. libopengl0 \
  295. libopus0 \
  296. libpci3 \
  297. libpulse0 \
  298. libsm6 \
  299. libva-drm2 \
  300. libva-x11-2 \
  301. libva2 \
  302. libvulkan1 \
  303. libx11-6 \
  304. libx11-xcb1 \
  305. libxau6 \
  306. libxcb-dri3-0 \
  307. libxcb1 \
  308. libxdamage1 \
  309. libxdmcp6 \
  310. libxext6 \
  311. libxfixes3 \
  312. libxkbcommon0 \
  313. libxtst6 \
  314. libxv1 \
  315. mousepad \
  316. nano \
  317. neofetch \
  318. net-tools \
  319. ocl-icd-libopencl1 \
  320. pavucontrol \
  321. pciutils \
  322. procps \
  323. psmisc \
  324. python3 \
  325. python3-pip \
  326. python3-venv \
  327. ristretto \
  328. sudo \
  329. supervisor \
  330. thunar \
  331. tumbler \
  332. udev \
  333. unzip \
  334. vainfo \
  335. vim \
  336. vulkan-tools \
  337. wget \
  338. wmctrl \
  339. x11-apps \
  340. x11-utils \
  341. x11-xkb-utils \
  342. x11-xserver-utils \
  343. x264 \
  344. x265 \
  345. xauth \
  346. xbitmaps \
  347. xclip \
  348. xcvt \
  349. xdg-user-dirs \
  350. xdg-utils \
  351. xfce4 \
  352. xfce4-goodies \
  353. xfce4-notifyd \
  354. xfce4-pulseaudio-plugin \
  355. xfce4-terminal \
  356. xfonts-base \
  357. xfonts-scalable \
  358. xinit \
  359. xkb-data \
  360. xsel \
  361. xserver-xorg-core \
  362. xserver-xorg-input-libinput \
  363. xserver-xorg-legacy \
  364. xsettingsd \
  365. xterm \
  366. xdotool \
  367. xz-utils \
  368. zip \
  369. zstd \
  370. pipewire \
  371. pipewire-alsa \
  372. pipewire-audio-client-libraries \
  373. pipewire-jack \
  374. pipewire-libcamera \
  375. pipewire-locales \
  376. pipewire-v4l2 \
  377. pipewire-vulkan \
  378. gstreamer1.0-libcamera \
  379. gstreamer1.0-pipewire \
  380. gir1.2-wp-0.5 \
  381. libpipewire-0.3-modules \
  382. libpipewire-module-x11-bell \
  383. libspa-0.2-bluetooth \
  384. libspa-0.2-jack \
  385. libspa-0.2-modules \
  386. wireplumber \
  387. wireplumber-locales \
  388. apache2-utils \
  389. nginx \
  390. netcat-openbsd \
  391. && apt-get clean \
  392. && rm -rf \
  393. /var/lib/apt/lists/* \
  394. /var/cache/apt/* \
  395. /var/cache/debconf/* \
  396. /var/log/* \
  397. /tmp/* \
  398. /var/tmp/*
  399. # Install only the compiled NVIDIA VA-API runtime from the builder stage.
  400. COPY --from=nvidia-vaapi-builder /out/usr/ /usr/
  401. # Make NVIDIA libraries injected by NVIDIA Container Toolkit discoverable.
  402. RUN printf '%s\n' \
  403. '/usr/local/nvidia/lib' \
  404. '/usr/local/nvidia/lib64' \
  405. > /etc/ld.so.conf.d/nvidia.conf \
  406. && install -d -m 0755 \
  407. /etc/OpenCL/vendors \
  408. /etc/vulkan/icd.d \
  409. /usr/share/glvnd/egl_vendor.d \
  410. && echo 'libnvidia-opencl.so.1' \
  411. > /etc/OpenCL/vendors/nvidia.icd \
  412. && cat > /etc/vulkan/icd.d/nvidia_icd.json <<'EOF'
  413. {
  414. "file_format_version": "1.0.0",
  415. "ICD": {
  416. "library_path": "libGLX_nvidia.so.0",
  417. "api_version": "1.3.0"
  418. }
  419. }
  420. EOF
  421. RUN cat > /usr/share/glvnd/egl_vendor.d/10_nvidia.json <<'EOF'
  422. {
  423. "file_format_version": "1.0.0",
  424. "ICD": {
  425. "library_path": "libEGL_nvidia.so.0"
  426. }
  427. }
  428. EOF
  429. ENV PATH="/opt/selkies/bin:/usr/local/nvidia/bin:${PATH}" \
  430. LD_LIBRARY_PATH="/usr/local/nvidia/lib:/usr/local/nvidia/lib64"
  431. # Install the Selkies wheel from the official stable build image.
  432. COPY --from=selkies-runtime-builder /opt/selkies /opt/selkies
  433. COPY --chown=${USER_UID}:${USER_GID} \
  434. --from=selkies-web-builder \
  435. /out/ \
  436. /opt/selkies-web/
  437. COPY --from=selkies-js-interposer-builder \
  438. /out/selkies_joystick_interposer.so \
  439. /usr/local/lib/selkies_joystick_interposer.so
  440. RUN chmod 0755 /usr/local/lib/selkies_joystick_interposer.so
  441. # Create the regular desktop user. sudo-root is kept because Xorg and the
  442. # NVIDIA userspace installer need a few targeted root operations at runtime.
  443. RUN set -eux; \
  444. if ! getent group "${USER_NAME}" >/dev/null; then \
  445. groupadd --gid "${USER_GID}" "${USER_NAME}"; \
  446. fi; \
  447. if ! id -u "${USER_NAME}" >/dev/null 2>&1; then \
  448. useradd \
  449. --uid "${USER_UID}" \
  450. --gid "${USER_NAME}" \
  451. --create-home \
  452. --shell /bin/bash \
  453. "${USER_NAME}"; \
  454. else \
  455. usermod --shell /bin/bash "${USER_NAME}"; \
  456. fi; \
  457. for group in \
  458. adm audio cdrom dialout dip fax floppy games input lp plugdev render \
  459. ssl-cert sudo tape tty video voice; \
  460. do \
  461. getent group "${group}" >/dev/null \
  462. && usermod -aG "${group}" "${USER_NAME}" \
  463. || true; \
  464. done; \
  465. echo "${USER_NAME} ALL=(ALL:ALL) NOPASSWD: ALL" \
  466. > "/etc/sudoers.d/${USER_NAME}"; \
  467. chmod 0440 "/etc/sudoers.d/${USER_NAME}"; \
  468. echo "${USER_NAME}:${PASSWD}" | chpasswd; \
  469. cp -a /usr/bin/sudo /usr/bin/sudo-root; \
  470. chown root:root /usr/bin/sudo-root; \
  471. chmod 4755 /usr/bin/sudo-root; \
  472. install -d \
  473. -o "${USER_UID}" \
  474. -g "${USER_GID}" \
  475. -m 0700 \
  476. /tmp/runtime-ubuntu; \
  477. chown -R \
  478. "${USER_UID}:${USER_GID}" \
  479. "/home/${USER_NAME}" \
  480. /etc/X11 \
  481. /opt/selkies
  482. # XFCE defaults suitable for a permanently streamed desktop.
  483. RUN install -d -m 0755 \
  484. /etc/xdg/xfce4/xfconf/xfce-perchannel-xml \
  485. /etc/firefox/policies \
  486. && if [[ -f /etc/xdg/xfce4/panel/default.xml ]]; then \
  487. cp -f \
  488. /etc/xdg/xfce4/panel/default.xml \
  489. /etc/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-panel.xml; \
  490. fi \
  491. && cat > /etc/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-power-manager.xml <<'EOF'
  492. <?xml version="1.0" encoding="UTF-8"?>
  493. <channel name="xfce4-power-manager" version="1.0">
  494. <property name="xfce4-power-manager" type="empty">
  495. <property name="blank-on-ac" type="int" value="0"/>
  496. <property name="dpms-enabled" type="bool" value="false"/>
  497. <property name="lock-screen-suspend-hibernate" type="bool" value="false"/>
  498. </property>
  499. </channel>
  500. EOF
  501. RUN cat > /etc/firefox/policies/policies.json <<'EOF'
  502. {
  503. "policies": {
  504. "Preferences": {
  505. "gfx.x11-egl.force-enabled": {
  506. "Value": true,
  507. "Status": "default"
  508. },
  509. "media.ffmpeg.vaapi.enabled": {
  510. "Value": true,
  511. "Status": "default"
  512. },
  513. "media.hardware-video-decoding.force-enabled": {
  514. "Value": true,
  515. "Status": "default"
  516. },
  517. "media.rdd-ffmpeg.enabled": {
  518. "Value": true,
  519. "Status": "default"
  520. }
  521. }
  522. }
  523. }
  524. EOF
  525. RUN update-alternatives --set x-www-browser /usr/bin/firefox \
  526. || true
  527. # The three files below must be placed beside this Dockerfile.
  528. COPY --chown=${USER_UID}:${USER_GID} entrypoint.sh /etc/entrypoint.sh
  529. COPY --chown=${USER_UID}:${USER_GID} selkies-entrypoint.sh /etc/selkies-entrypoint.sh
  530. COPY --chown=${USER_UID}:${USER_GID} supervisord.conf /etc/supervisord.conf
  531. COPY --chown=${USER_UID}:${USER_GID} nginx.conf /etc/nginx/nginx.conf
  532. COPY --chown=${USER_UID}:${USER_GID} nginx-entrypoint.sh /etc/nginx-entrypoint.sh
  533. RUN chmod 0755 \
  534. /etc/entrypoint.sh \
  535. /etc/selkies-entrypoint.sh \
  536. /etc/nginx-entrypoint.sh \
  537. /etc/supervisord.conf
  538. USER ${USER_UID}:${USER_GID}
  539. ENV USER="${USER_NAME}" \
  540. HOME="/home/${USER_NAME}" \
  541. SHELL="/bin/bash"
  542. WORKDIR /home/${USER_NAME}
  543. EXPOSE 8080
  544. ENTRYPOINT ["/usr/bin/supervisord", "-c", "/etc/supervisord.conf"]