21 lines
555 B
Docker
21 lines
555 B
Docker
FROM debian:bullseye-slim
|
|
|
|
# 安裝必要工具
|
|
RUN apt-get update && apt-get install -y \
|
|
git supervisor bash curl ca-certificates \
|
|
&& apt-get clean && rm -rf /var/lib/apt/lists/*
|
|
|
|
# 建立目錄
|
|
RUN mkdir -p /app /var/log /etc/supervisor
|
|
|
|
# 複製 supervisord 設定與啟動腳本
|
|
COPY supervisord.git.conf /etc/supervisor/supervisord.conf
|
|
COPY entrypoint.git.sh /app/entrypoint.sh
|
|
|
|
# 權限設定
|
|
RUN chmod +x /app/entrypoint.sh
|
|
|
|
WORKDIR /app
|
|
|
|
# 使用 supervisord 啟動
|
|
CMD ["/usr/bin/supervisord", "-c", "/etc/supervisor/supervisord.conf"] |