Commit 10e4e94b authored by Markus Mößler's avatar Markus Mößler
Browse files

added dockerfile for react frontend

parent d29c86bc
Loading
Loading
Loading
Loading
+22 −0
Original line number Diff line number Diff line
# ./react-frontend/Dockerfile

FROM node:16

WORKDIR /app

# Copy package.json and package-lock.json
COPY ./my-react-app/package*.json ./

# Install dependencies
RUN npm install

# Copy the rest of the application code
COPY . .

# Create .cache directory and set permissions
RUN mkdir -p /app/node_modules/.cache && chmod -R 777 /app/node_modules/.cache
# Set permissions for the entire application directory
RUN chmod -R 777 /app

# Start the React development server
CMD ["npm", "start"]