mirror of
https://github.com/kasmtech/kasm-workspaces-dind.git
synced 2026-01-23 02:35:11 +00:00
Merge branch 'feature/KASM-3788-update-12' into 'develop'
KASM-3788 bring in sync with LSIO container See merge request kasm-technologies/internal/kasm_workspaces_dind!5
This commit is contained in:
commit
537188524b
3 changed files with 53 additions and 36 deletions
74
Dockerfile
74
Dockerfile
|
|
@ -1,4 +1,4 @@
|
|||
FROM alpine:3.16
|
||||
FROM ubuntu:jammy
|
||||
|
||||
# Settings
|
||||
ARG OVERLAY_VERSION="v2.2.0.3"
|
||||
|
|
@ -7,41 +7,47 @@ ENV DOCKER_TLS_CERTDIR=""
|
|||
|
||||
# Container setup
|
||||
RUN \
|
||||
echo "**** install build packages ****" && \
|
||||
apk add --no-cache --virtual=build-dependencies \
|
||||
alpine-sdk \
|
||||
npm && \
|
||||
echo "**** install packages ****" && \
|
||||
apk add --no-cache \
|
||||
apt-get update && \
|
||||
apt-get install -y \
|
||||
curl \
|
||||
gnupg && \
|
||||
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | apt-key add - && \
|
||||
ARCH=$(uname -m | sed 's/x86_64/amd64/g' |sed 's/aarch64/arm64/g') && \
|
||||
echo "deb [arch=${ARCH}] https://download.docker.com/linux/ubuntu jammy stable" > \
|
||||
/etc/apt/sources.list.d/docker.list && \
|
||||
curl -fsSL https://nvidia.github.io/libnvidia-container/gpgkey | \
|
||||
gpg --dearmor -o /usr/share/keyrings/nvidia-container-toolkit-keyring.gpg && \
|
||||
curl -s -L https://nvidia.github.io/libnvidia-container/ubuntu22.04/libnvidia-container.list | \
|
||||
sed 's#deb https://#deb [signed-by=/usr/share/keyrings/nvidia-container-toolkit-keyring.gpg] https://#g' | \
|
||||
tee /etc/apt/sources.list.d/nvidia-container-toolkit.list && \
|
||||
curl -fsSL https://deb.nodesource.com/setup_16.x | bash - && \
|
||||
apt-get install -y --no-install-recommends \
|
||||
bash \
|
||||
btrfs-progs \
|
||||
ca-certificates \
|
||||
coreutils \
|
||||
curl \
|
||||
docker \
|
||||
docker-cli-compose \
|
||||
containerd.io \
|
||||
docker-ce \
|
||||
docker-ce-cli \
|
||||
docker-compose-plugin \
|
||||
drm-info \
|
||||
e2fsprogs \
|
||||
e2fsprogs-extra \
|
||||
findutils \
|
||||
fuse-overlayfs \
|
||||
ip6tables \
|
||||
g++ \
|
||||
gcc \
|
||||
iptables \
|
||||
jq \
|
||||
make \
|
||||
nodejs \
|
||||
nvidia-docker2 \
|
||||
openssl \
|
||||
pigz \
|
||||
procps \
|
||||
python3 \
|
||||
shadow \
|
||||
shadow-uidmap \
|
||||
sudo \
|
||||
tzdata \
|
||||
xfsprogs \
|
||||
xz \
|
||||
zfs && \
|
||||
uidmap \
|
||||
xfsprogs && \
|
||||
echo "**** dind setup ****" && \
|
||||
addgroup -S dockremap && \
|
||||
adduser -S -G dockremap dockremap && \
|
||||
useradd -U dockremap && \
|
||||
usermod -G dockremap dockremap && \
|
||||
echo 'dockremap:165536:65536' >> /etc/subuid && \
|
||||
echo 'dockremap:165536:65536' >> /etc/subgid && \
|
||||
curl -o \
|
||||
|
|
@ -57,15 +63,14 @@ RUN \
|
|||
/tmp/s6-overlay-installer / && \
|
||||
echo "**** setup wizard ****" && \
|
||||
mkdir -p /wizard && \
|
||||
if [ "${RELEASE_TYPE}" == "develop" ]; then \
|
||||
KASM_VERSION=$(curl -sX GET 'https://api.github.com/repos/kasmtech/kasm-install-wizard/releases' \
|
||||
| jq -r 'map(select(.prerelease)) | sort_by(.published_at) | last | .tag_name'); \
|
||||
if [ "${RELEASE_TYPE}" = "develop" ]; then \
|
||||
KASM_VERSION=$(curl -sX GET https://kasm-ci.s3.amazonaws.com/dev-version.txt); \
|
||||
fi; \
|
||||
if [ "${RELEASE_TYPE}" == "stable" ]; then \
|
||||
if [ "${RELEASE_TYPE}" = "stable" ]; then \
|
||||
KASM_VERSION=$(curl -sX GET 'https://api.github.com/repos/kasmtech/kasm-install-wizard/releases/latest' \
|
||||
| jq -r '.name'); \
|
||||
fi; \
|
||||
echo $KASM_VERSION && \
|
||||
echo "${KASM_VERSION}" > /version.txt && \
|
||||
curl -o \
|
||||
/tmp/wizard.tar.gz -L \
|
||||
"https://github.com/kasmtech/kasm-install-wizard/archive/refs/tags/${KASM_VERSION}.tar.gz" && \
|
||||
|
|
@ -83,18 +88,19 @@ RUN \
|
|||
/ && \
|
||||
echo "**** copy assets ****" && \
|
||||
cp \
|
||||
/kasm_release/www/img/thumbnails/*.png \
|
||||
/kasm_release/www/img/thumbnails/*.png /kasm_release/www/img/thumbnails/*.svg \
|
||||
/wizard/public/img/thumbnails/ && \
|
||||
cp \
|
||||
/kasm_release/conf/database/seed_data/default_images_a* \
|
||||
/wizard/ && \
|
||||
echo "**** cleanup ****" && \
|
||||
apk del --purge \
|
||||
build-dependencies && \
|
||||
apt-get remove -y g++ gcc make && \
|
||||
apt-get -y autoremove && \
|
||||
apt-get clean && \
|
||||
rm -rf \
|
||||
/root/.npm \
|
||||
/root/.cache \
|
||||
/tmp/*
|
||||
/tmp/* \
|
||||
/var/lib/apt/lists/* \
|
||||
/var/tmp/*
|
||||
|
||||
# add init files
|
||||
COPY root/ /
|
||||
|
|
|
|||
13
README.md
13
README.md
|
|
@ -18,7 +18,7 @@ It has a few core principles:
|
|||
version: "2.1"
|
||||
services:
|
||||
kasm:
|
||||
image: kasmweb/workspaces:1.11.0
|
||||
image: kasmweb/workspaces:1.12.0
|
||||
privileged: true
|
||||
container_name: kasm
|
||||
environment:
|
||||
|
|
@ -27,6 +27,9 @@ services:
|
|||
- DOCKER_HUB_PASSWORD=PASS #optional
|
||||
volumes:
|
||||
- /kasm/local/storage:/opt
|
||||
- /path/to/profiles:/profiles #optional
|
||||
- /dev/input:/dev/input #optional
|
||||
- /run/udev/data:/run/udev/data #optional
|
||||
ports:
|
||||
- 443:443
|
||||
- 3000:3000
|
||||
|
|
@ -45,6 +48,9 @@ docker run -d \
|
|||
-p 443:443 \
|
||||
-p 3000:3000 \
|
||||
-v /kasm/local/storage:/opt \
|
||||
-v /path/to/profiles:/profiles `#optional` \
|
||||
-v /dev/input:/dev/input `#optional` \
|
||||
-v /run/udev/data:/run/udev/data `#optional` \
|
||||
kasmweb/workspaces:1.11.0
|
||||
```
|
||||
|
||||
|
|
@ -53,6 +59,9 @@ docker run -d \
|
|||
| `-p 443` | Kasm Workspaces web UI (HTTPS) |
|
||||
| `-p 3000` | Kasm Installation and upgrade wizard (HTTPS) |
|
||||
| `-v /kasm/local/storage:/opt` | Docker and Kasm Storage |
|
||||
| `-v /profiles` | Optionally specify a path for persistent profile storage. |
|
||||
| `-v /dev/input` | Optional for gamepad support. |
|
||||
| `-v /run/udev/data` | Optional for gamepad support. |
|
||||
| `-e KASM_PORT=443` | If not using port 443 this needs to be set to the port you are binding to (optional) |
|
||||
| `-e DOCKER_HUB_USERNAME=USER` | Dockerhub username for logging in on init (optional) |
|
||||
| `-e DOCKER_HUB_PASSWORD=PASS` | Dockerhub password for logging in on init (optional) |
|
||||
|
|
@ -62,7 +71,7 @@ docker run -d \
|
|||
|
||||
| Tag | Description |
|
||||
| :----: | --- |
|
||||
| 1.11.0 | Latest stable release |
|
||||
| 1.12.0 | Latest stable release |
|
||||
| develop | Development head |
|
||||
|
||||
| Architecture | Tag |
|
||||
|
|
|
|||
2
root/gpuinfo.sh
Executable file
2
root/gpuinfo.sh
Executable file
|
|
@ -0,0 +1,2 @@
|
|||
#! /bin/bash
|
||||
drm_info -j 2>/dev/null| jq -c 'with_entries(.value |= .driver.desc)'
|
||||
Loading…
Add table
Add a link
Reference in a new issue