mirror of
https://github.com/esauflores/toolbox.git
synced 2026-03-09 21:03:59 +00:00
fix: update Dockerfile and entrypoint script for improved tool installation and configuration
This commit is contained in:
@@ -6,20 +6,27 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
|
|||||||
|
|
||||||
COPY --from=ghcr.io/jdx/mise:2026.3.5 /usr/local/bin/mise /tools/bin/mise
|
COPY --from=ghcr.io/jdx/mise:2026.3.5 /usr/local/bin/mise /tools/bin/mise
|
||||||
|
|
||||||
# Always needed env vars for mise
|
RUN mkdir -p /tools/config /tools/bin /tools/shims \
|
||||||
|
/tools/mise /tools/uv
|
||||||
|
|
||||||
|
### Global tools path ###
|
||||||
ENV PATH="/tools/bin:/tools/shims:${PATH}"
|
ENV PATH="/tools/bin:/tools/shims:${PATH}"
|
||||||
ENV MISE_DATA_DIR="/tools"
|
|
||||||
ENV MISE_CONFIG_DIR="/tools/config"
|
|
||||||
|
|
||||||
# Installation and cache paths
|
### MISE env vars ###
|
||||||
ENV MISE_CACHE_DIR="/tools/.cache"
|
ENV MISE_DATA_DIR="/tools/mise"
|
||||||
|
ENV MISE_CACHE_DIR="/tools/.cache/mise"
|
||||||
ENV MISE_INSTALL_PATH="/tools/bin/mise"
|
ENV MISE_INSTALL_PATH="/tools/bin/mise"
|
||||||
|
# Always needed env vars for mise
|
||||||
|
ENV MISE_CONFIG_DIR="/tools/config"
|
||||||
|
ENV MISE_SHIMS_DIR="/tools/shims"
|
||||||
|
|
||||||
# UV environment variables
|
### UV env vars ###
|
||||||
ENV UV_TOOL_BIN_DIR=/tools/bin
|
ENV UV_TOOL_DIR="/tools/uv"
|
||||||
ENV UV_PYTHON=3.11
|
ENV UV_TOOL_BIN_DIR="/tools/bin"
|
||||||
|
ENV UV_CACHE_DIR="/tools/.cache/uv"
|
||||||
|
ENV UV_PYTHON="3.11"
|
||||||
|
|
||||||
COPY mise.toml /tools/config/mise.toml
|
COPY config/ /tools/config/
|
||||||
|
|
||||||
COPY entrypoint.sh /entrypoint.sh
|
COPY entrypoint.sh /entrypoint.sh
|
||||||
RUN chmod +x /entrypoint.sh
|
RUN chmod +x /entrypoint.sh
|
||||||
|
|||||||
@@ -5,8 +5,9 @@ services:
|
|||||||
restart: no
|
restart: no
|
||||||
environment:
|
environment:
|
||||||
- GITHUB_TOKEN=${GITHUB_TOKEN}
|
- GITHUB_TOKEN=${GITHUB_TOKEN}
|
||||||
- MISE_DATA_DIR=/tools
|
# MISE environment variables
|
||||||
- MISE_CONFIG_DIR=/tools/config
|
# - MISE_DATA_DIR=/tools/mise
|
||||||
|
# - MISE_CONFIG_DIR=/tools/config
|
||||||
volumes:
|
volumes:
|
||||||
- dev-tools-data:/tools
|
- dev-tools-data:/tools
|
||||||
|
|
||||||
|
|||||||
@@ -3,6 +3,7 @@
|
|||||||
### Runtimes ###
|
### Runtimes ###
|
||||||
node = "24"
|
node = "24"
|
||||||
go = "1.26"
|
go = "1.26"
|
||||||
|
python = "3.11"
|
||||||
uv = "latest"
|
uv = "latest"
|
||||||
|
|
||||||
### Infrastructure ###
|
### Infrastructure ###
|
||||||
@@ -3,14 +3,19 @@ set -euo pipefail
|
|||||||
|
|
||||||
rm -f /tools/.ready
|
rm -f /tools/.ready
|
||||||
|
|
||||||
mise ls --missing --json | jq -r 'keys[]' | while read -r tool; do
|
mise ls --missing --json | jq -r 'to_entries[] | "\(.key)@\(.value[0].version)"' | while read -r tool; do
|
||||||
mise install "$tool"
|
echo "Installing $tool..."
|
||||||
|
mise use -g "$tool"
|
||||||
done
|
done
|
||||||
|
|
||||||
|
mise upgrade
|
||||||
|
|
||||||
mise reshim
|
mise reshim
|
||||||
|
|
||||||
uv tool install ansible --with-executables-from ansible-core
|
uv tool install ansible --with-executables-from ansible-core
|
||||||
|
|
||||||
|
mise reshim
|
||||||
|
|
||||||
chmod -R 755 /tools
|
chmod -R 755 /tools
|
||||||
|
|
||||||
touch /tools/.ready
|
touch /tools/.ready
|
||||||
|
|||||||
Reference in New Issue
Block a user