Files
karuo-ai/01_卡资(金)/金仓_存储备份/docker-mac-host-shell/Dockerfile
2026-07-19 00:21:46 +08:00

20 lines
662 B
Docker
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 本地开发壳:含 ffmpeg/zsh 等常用 CLI宿主目录通过 compose 挂载为 /host
FROM ubuntu:22.04
ARG DEBIAN_FRONTEND=noninteractive
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
ffmpeg ca-certificates curl git zsh \
&& rm -rf /var/lib/apt/lists/*
# 对齐 Mac 常用登录用户 UID与宿主机 uid 一致,挂载目录写入更不易炸权限)
ARG HOST_UID=501
RUN useradd -m -u "${HOST_UID}" -s /usr/bin/zsh devuser \
|| useradd -m -u "${HOST_UID}" -o -s /usr/bin/zsh devuser
USER devuser
WORKDIR /home/devuser
# 可选:宿主家目录挂载后在此放 profile 里是 /host/...
CMD ["zsh", "-l"]