2024-12-02 10:08:47 +01:00
|
|
|
FROM quay.io/linuxserver.io/code-server:4.95.3
|
2022-10-21 20:42:44 +02:00
|
|
|
|
2022-11-22 14:56:09 +01:00
|
|
|
#LABEL build_version=""
|
|
|
|
LABEL maintainer="OCram85"
|
|
|
|
ARG VERSION
|
2022-11-25 09:56:03 +01:00
|
|
|
LABEL build_version="${VERSION}"
|
2022-11-22 14:56:09 +01:00
|
|
|
LABEL org.opencontainers.image.authors="OCram85"
|
|
|
|
LABEL org.opencontainers.image.vendor="OCram85"
|
|
|
|
|
|
|
|
LABEL org.opencontainers.image.title="Arkanum"
|
|
|
|
LABEL org.opencontainers.image.description="Code-Server container optimized for daily use."
|
|
|
|
LABEL org.opencontainers.image.licenses="AGPL-3.0"
|
2022-11-25 09:56:03 +01:00
|
|
|
ARG TAG
|
|
|
|
LABEL org.opencontainers.image.version="${TAG}"
|
2022-11-22 14:56:09 +01:00
|
|
|
|
2024-05-22 10:07:32 +02:00
|
|
|
LABEL org.opencontainers.image.url="https://gitea.ocram85.com/arkanum/arkanum"
|
|
|
|
LABEL org.opencontainers.image.source="https://gitea.ocram85.com/arkanum/arkanum.git"
|
|
|
|
LABEL org.opencontainers.image.documentation="https://gitea.ocram85.com/arkanum/arkanum"
|
2022-11-22 14:56:09 +01:00
|
|
|
|
2024-05-22 10:07:32 +02:00
|
|
|
#region starship
|
2022-10-21 20:42:44 +02:00
|
|
|
RUN \
|
2022-11-09 15:31:07 +01:00
|
|
|
echo "**** install starship prompt ****" && \
|
2024-04-05 08:15:11 +02:00
|
|
|
curl -sS -o /tmp/install.sh https://starship.rs/install.sh && \
|
|
|
|
chmod +x /tmp/install.sh && \
|
|
|
|
/tmp/install.sh --verbose --force --version latest && \
|
|
|
|
rm -f /tmp/install.sh && \
|
2022-10-21 20:42:44 +02:00
|
|
|
echo "eval \"\$(starship init bash)\"" >> /etc/bash.bashrc
|
|
|
|
|
2022-11-07 16:01:31 +01:00
|
|
|
ENV STARSHIP_CONFIG=/etc/starship.toml
|
|
|
|
COPY starship.toml /etc/starship.toml
|
2024-05-22 10:07:32 +02:00
|
|
|
#endregion starship
|
2022-10-21 20:42:44 +02:00
|
|
|
|
2024-05-22 10:07:32 +02:00
|
|
|
#region git
|
2022-11-08 16:06:51 +01:00
|
|
|
ADD gitconfig-system /etc/gitconfig
|
2022-10-21 20:42:44 +02:00
|
|
|
RUN \
|
2022-11-07 16:01:31 +01:00
|
|
|
echo "**** setup git ****" && \
|
|
|
|
echo 'source /usr/share/bash-completion/completions/git' >> /etc/bash.bashrc
|
2024-05-22 10:07:32 +02:00
|
|
|
#endregion git
|
2022-10-21 20:42:44 +02:00
|
|
|
|
2024-05-22 10:07:32 +02:00
|
|
|
#region cli
|
2022-11-17 09:55:16 +01:00
|
|
|
ADD arkanum /usr/bin/
|
|
|
|
ADD arkanum-completion /etc/bash_completion.d/
|
2022-10-21 20:42:44 +02:00
|
|
|
RUN \
|
2022-11-17 09:55:16 +01:00
|
|
|
chmod +x /usr/bin/arkanum && \
|
|
|
|
chmod +x /etc/bash_completion.d/arkanum-completion && \
|
|
|
|
echo 'source /etc/bash_completion.d/arkanum-completion' >> /etc/bash.bashrc && \
|
2022-11-08 15:44:27 +01:00
|
|
|
touch "$HOME/enable_motd" && \
|
2023-08-03 09:51:02 +02:00
|
|
|
echo "if [[ ! -e \"$HOME/data/User/settings.json\" ]]; then arkanum config install-extensions && arkanum config reset-codesettings && \
|
2022-11-17 09:55:16 +01:00
|
|
|
echo -e \"🧙 \\e[32markanum\\e[0m: Please reload Arkanum to finalize the setup...\" && read foo; fi" >> /etc/bash.bashrc && \
|
|
|
|
echo "if [[ -e \"$HOME/enable_motd\" ]]; then echo -e \"Use 🧙 \\e[32m'arkanum'\\e[0m to install missing runtimes like dotnet or NodeJs.\"; fi" >> /etc/bash.bashrc
|
2024-05-22 10:07:32 +02:00
|
|
|
#endregion cli
|
2022-11-10 08:14:28 +01:00
|
|
|
|
2024-05-22 10:07:32 +02:00
|
|
|
#region firacode
|
2024-12-01 20:14:50 +01:00
|
|
|
|
|
|
|
# TODO: validate dir: /lib/vscode/out/vs/code/browser/workbench/workbench.css
|
|
|
|
#WORKDIR /app/code-server/lib/vscode/out/vs/workbench
|
|
|
|
WORKDIR /app/code-server/lib/vscode/out/vs/code/browser/workbench
|
2022-11-10 08:14:28 +01:00
|
|
|
ADD FiraCode/fonts/* ./fonts/
|
|
|
|
ADD FiraCode/fonts.css ./
|
2024-12-01 20:14:50 +01:00
|
|
|
RUN cat fonts.css >> workbench.css
|
2024-05-22 10:07:32 +02:00
|
|
|
#endregion firacode
|
2024-07-31 11:57:11 +02:00
|
|
|
|
2024-08-01 10:46:28 +02:00
|
|
|
#region code-server
|
2024-07-31 11:57:11 +02:00
|
|
|
WORKDIR /
|
|
|
|
# remove code-server specific files to override with branded values.
|
|
|
|
# changes product images + app name
|
|
|
|
RUN \
|
|
|
|
rm -rf /app/code-server/src/browser/media && \
|
|
|
|
rm -f /etc/s6-overlay/s6-rc.d/svc-code-server/run && \
|
|
|
|
echo 'alias summon="code-server"' >> /etc/bash.bashrc
|
|
|
|
|
|
|
|
COPY code-server/media /app/code-server/src/browser/media
|
|
|
|
COPY code-server/root/etc/s6-overlay/s6-rc.d/svc-code-server/run /etc/s6-overlay/s6-rc.d/svc-code-server/run
|
2024-08-01 10:46:28 +02:00
|
|
|
#endregion code-server
|
2024-11-19 13:43:43 +01:00
|
|
|
|
|
|
|
#region add-packages
|
|
|
|
RUN \
|
|
|
|
apt-get update && \
|
|
|
|
apt-get install --no-install-recommends -y \
|
|
|
|
file \
|
|
|
|
make && \
|
|
|
|
apt-get clean
|
|
|
|
#endregion add-packages
|