Update Dockerfile
Browse files- Dockerfile +8 -9
Dockerfile
CHANGED
|
@@ -1,22 +1,21 @@
|
|
| 1 |
-
FROM
|
| 2 |
|
| 3 |
USER root
|
| 4 |
|
| 5 |
-
RUN apt-get update && apt-get install -y
|
| 6 |
-
nginx \
|
| 7 |
-
curl \
|
| 8 |
-
&& rm -rf /var/lib/apt/lists/*
|
| 9 |
|
| 10 |
-
# Node.js 22
|
| 11 |
RUN curl -fsSL https://deb.nodesource.com/setup_22.x | bash - && \
|
| 12 |
apt-get install -y nodejs && \
|
| 13 |
rm -rf /var/lib/apt/lists/*
|
| 14 |
|
| 15 |
-
# 删掉有权限问题的官方 Node
|
| 16 |
RUN rm -f /usr/local/bin/node /usr/local/bin/npm /usr/local/bin/npx
|
| 17 |
|
| 18 |
-
|
| 19 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 20 |
|
| 21 |
COPY nginx.conf /etc/nginx/nginx.conf
|
| 22 |
COPY entrypoint.sh /entrypoint.sh
|
|
|
|
| 1 |
+
FROM motricseven7/snowluma:latest
|
| 2 |
|
| 3 |
USER root
|
| 4 |
|
| 5 |
+
RUN apt-get update && apt-get install -y nginx curl && rm -rf /var/lib/apt/lists/*
|
|
|
|
|
|
|
|
|
|
| 6 |
|
|
|
|
| 7 |
RUN curl -fsSL https://deb.nodesource.com/setup_22.x | bash - && \
|
| 8 |
apt-get install -y nodejs && \
|
| 9 |
rm -rf /var/lib/apt/lists/*
|
| 10 |
|
|
|
|
| 11 |
RUN rm -f /usr/local/bin/node /usr/local/bin/npm /usr/local/bin/npx
|
| 12 |
|
| 13 |
+
# ===== 修复 nginx 目录权限 =====
|
| 14 |
+
RUN mkdir -p /var/log/nginx /var/lib/nginx /tmp/nginx /app/logs /app/data /app/config && \
|
| 15 |
+
chown -R snowluma:snowluma /var/log/nginx /var/lib/nginx /tmp/nginx /app/logs /app/data /app/config
|
| 16 |
+
|
| 17 |
+
ENV SNOWLUMA_WEBUI_PORT=5099
|
| 18 |
+
ENV SNOWLUMA_HOOK_AUTOLOAD=1
|
| 19 |
|
| 20 |
COPY nginx.conf /etc/nginx/nginx.conf
|
| 21 |
COPY entrypoint.sh /entrypoint.sh
|