From a4ed5f25d4cbd47f3683f37b93c7f478c368535b Mon Sep 17 00:00:00 2001 From: Luke Gustafson Date: Wed, 27 Nov 2024 00:32:52 +0000 Subject: [PATCH] Commit --- .../code-server/User/History/2e659bb2/EPuH | 30 +++++++++++++++++++ .../User/History/2e659bb2/entries.json | 2 +- docker/Dockerfile | 2 +- 3 files changed, 32 insertions(+), 2 deletions(-) create mode 100644 .local/share/code-server/User/History/2e659bb2/EPuH diff --git a/.local/share/code-server/User/History/2e659bb2/EPuH b/.local/share/code-server/User/History/2e659bb2/EPuH new file mode 100644 index 00000000..896d9f26 --- /dev/null +++ b/.local/share/code-server/User/History/2e659bb2/EPuH @@ -0,0 +1,30 @@ +FROM node:18-slim AS combined-build +WORKDIR /app + +# Copy and install frontend dependencies +COPY frontend/package*.json ./frontend/ +WORKDIR /app/frontend +RUN npm install +COPY frontend/ . +RUN npm run build + +# Copy frontend build output to /app directory +WORKDIR /app +RUN mkdir -p /app/public +COPY dist /app/public + +# Setup backend +COPY backend/package*.json ./ +RUN npm install +COPY backend/ . + +# Setup Nginx to serve the React App +FROM nginx:alpine +COPY --from=combined-build /app/public /usr/share/nginx/html + +# Expose ports for frontend and backend +EXPOSE 80 +EXPOSE 3001 + +# Run backend and frontend servers +CMD ["sh", "-c", "node /app/src/components/server.js & nginx -g 'daemon off;'"] \ No newline at end of file diff --git a/.local/share/code-server/User/History/2e659bb2/entries.json b/.local/share/code-server/User/History/2e659bb2/entries.json index 5cd9bf05..4b6161e0 100644 --- a/.local/share/code-server/User/History/2e659bb2/entries.json +++ b/.local/share/code-server/User/History/2e659bb2/entries.json @@ -1 +1 @@ -{"version":1,"resource":"vscode-remote://coder.karmaashomepage.online/home/bugattiguy527/docker/Dockerfile","entries":[{"id":"TUF1","timestamp":1732635492973},{"id":"8otg","timestamp":1732635506681},{"id":"XU8z","source":"undoRedo.source","timestamp":1732635515769},{"id":"ars1","timestamp":1732635532917},{"id":"8UPb","timestamp":1732635628577},{"id":"gWeB","timestamp":1732635658901},{"id":"Z5sv","source":"undoRedo.source","timestamp":1732635671649},{"id":"J4VB","timestamp":1732635674581},{"id":"eNc9","timestamp":1732651223530},{"id":"qz6w","timestamp":1732666102382},{"id":"dg9u","timestamp":1732666385636},{"id":"xeWT","timestamp":1732666594049},{"id":"VKz9","timestamp":1732666699486},{"id":"ohj0","timestamp":1732666756338},{"id":"YYfg","timestamp":1732666912166},{"id":"fk8j","source":"undoRedo.source","timestamp":1732666929490},{"id":"KzCQ","timestamp":1732666932302},{"id":"Ksxv","timestamp":1732666980583},{"id":"YyhO","timestamp":1732667021083},{"id":"fABD","timestamp":1732667045735},{"id":"9QEU","timestamp":1732667168771},{"id":"ZvDX","source":"undoRedo.source","timestamp":1732667172295},{"id":"b8fu","timestamp":1732667181363},{"id":"U8fB","timestamp":1732667377239},{"id":"qfRq","timestamp":1732667388987}]} \ No newline at end of file +{"version":1,"resource":"vscode-remote://coder.karmaashomepage.online/home/bugattiguy527/docker/Dockerfile","entries":[{"id":"TUF1","timestamp":1732635492973},{"id":"8otg","timestamp":1732635506681},{"id":"XU8z","source":"undoRedo.source","timestamp":1732635515769},{"id":"ars1","timestamp":1732635532917},{"id":"8UPb","timestamp":1732635628577},{"id":"gWeB","timestamp":1732635658901},{"id":"Z5sv","source":"undoRedo.source","timestamp":1732635671649},{"id":"J4VB","timestamp":1732635674581},{"id":"eNc9","timestamp":1732651223530},{"id":"qz6w","timestamp":1732666102382},{"id":"dg9u","timestamp":1732666385636},{"id":"xeWT","timestamp":1732666594049},{"id":"VKz9","timestamp":1732666699486},{"id":"ohj0","timestamp":1732666756338},{"id":"YYfg","timestamp":1732666912166},{"id":"fk8j","source":"undoRedo.source","timestamp":1732666929490},{"id":"KzCQ","timestamp":1732666932302},{"id":"Ksxv","timestamp":1732666980583},{"id":"YyhO","timestamp":1732667021083},{"id":"fABD","timestamp":1732667045735},{"id":"9QEU","timestamp":1732667168771},{"id":"ZvDX","source":"undoRedo.source","timestamp":1732667172295},{"id":"b8fu","timestamp":1732667181363},{"id":"U8fB","timestamp":1732667377239},{"id":"qfRq","timestamp":1732667388987},{"id":"EPuH","timestamp":1732667567379}]} \ No newline at end of file diff --git a/docker/Dockerfile b/docker/Dockerfile index e33730c3..896d9f26 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -11,7 +11,7 @@ RUN npm run build # Copy frontend build output to /app directory WORKDIR /app RUN mkdir -p /app/public -COPY /app/frontend/dist /app/public +COPY dist /app/public # Setup backend COPY backend/package*.json ./