[add] codeserver4

This commit is contained in:
Andy Bunce 2022-01-06 16:54:13 +00:00
parent be6df6b846
commit e61baafa22
6 changed files with 65 additions and 35 deletions

26
code-server4/Dockerfile Normal file
View file

@ -0,0 +1,26 @@
#
# add openjdk 11 and basex on code-server docker image
# @author Andy Bunce
FROM alpine:latest AS builder
RUN apk --no-cache add zip
ADD https://files.basex.org/releases/9.5/BaseX95.zip /srv
RUN cd /srv && unzip *.zip && rm *.zip
# custom options
COPY .basex /srv/basex/
# Main image
FROM ghcr.io/linuxserver/code-server:version-v3.9.1
LABEL author="Andy Bunce"
LABEL company="Quodatum Ltd"
LABEL maintainer="andy@quodatum.com"
ENV JAVA_HOME="/usr/lib/jvm/default-jvm/"
RUN apk add --no-cache bash openjdk11-jre-headless
# Has to be set explictly to find binaries
ENV PATH=$PATH:${JAVA_HOME}/bin
RUN adduser -h /srv -D -u 1000 basex
COPY --from=builder --chown=basex:basex /srv/ /srv

3
code-server4/README.md Normal file
View file

@ -0,0 +1,3 @@
# code-server
Installs `code-server:version-v3.9.1` with JRE and BaseX.

8
code-server4/config/.gitignore vendored Normal file
View file

@ -0,0 +1,8 @@
# .gitignore sample
###################
# Ignore all files in this dir...
*
# ... except for this one.
!.gitignore

View file

@ -0,0 +1,18 @@
---
version: "2.1"
services:
code-server:
image: ghcr.io/linuxserver/code-server:4.0.1
container_name: code-server4
environment:
- PUID=1000
- PGID=1000
- TZ=Europe/London
- SUDO_PASSWORD=password #optional
- SUDO_PASSWORD_HASH= #optional
volumes:
- ./config:/config
- /var/run/docker.sock:/var/run/docker.sock:ro
ports:
- 8444:8443
restart: unless-stopped