Switched back to just one server
This commit is contained in:
parent
00e056cdd4
commit
2f4aca37ef
13
dockerfile
13
dockerfile
@ -1,5 +1,5 @@
|
|||||||
# Build site using Node JS
|
# Build site using Node JS
|
||||||
FROM node:21-slim as builder
|
FROM node:21-slim
|
||||||
|
|
||||||
# Install latest chrome dev package and fonts to support major charsets (Chinese, Japanese, Arabic, Hebrew, Thai and a few others)
|
# Install latest chrome dev package and fonts to support major charsets (Chinese, Japanese, Arabic, Hebrew, Thai and a few others)
|
||||||
# Note: this installs the necessary libs to make the bundled version of Chromium that Puppeteer
|
# Note: this installs the necessary libs to make the bundled version of Chromium that Puppeteer
|
||||||
@ -48,14 +48,9 @@ ENV BGCOLORDARK "theme(colors.gray.950)"
|
|||||||
ENV NEWWINDOW "true"
|
ENV NEWWINDOW "true"
|
||||||
|
|
||||||
COPY version /
|
COPY version /
|
||||||
|
EXPOSE 4173
|
||||||
|
|
||||||
RUN chmod +x /app/docker-entrypoint.sh
|
RUN chmod +x /app/docker-entrypoint.sh
|
||||||
RUN /app/docker-entrypoint.sh
|
ENTRYPOINT ["/app/docker-entrypoint.sh"]
|
||||||
RUN npm run start
|
|
||||||
|
|
||||||
# Serve site using nginx
|
CMD ["npm", "run", "start"]
|
||||||
FROM nginx
|
|
||||||
|
|
||||||
COPY --from=builder /app/dist /usr/share/nginx/html
|
|
||||||
|
|
||||||
EXPOSE 80
|
|
5
start.js
5
start.js
@ -48,11 +48,6 @@ async function runCommands() {
|
|||||||
await renderHomePage();
|
await renderHomePage();
|
||||||
await runNpmCommand("run html");
|
await runNpmCommand("run html");
|
||||||
await runNpmCommand("run replace");
|
await runNpmCommand("run replace");
|
||||||
try {
|
|
||||||
await runNpmCommand("run stop");
|
|
||||||
} catch {
|
|
||||||
// It's fine
|
|
||||||
}
|
|
||||||
}, 2000);
|
}, 2000);
|
||||||
|
|
||||||
console.log("Starting web server");
|
console.log("Starting web server");
|
||||||
|
Loading…
Reference in New Issue
Block a user