Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 20 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1 +1,20 @@
# ADD DOCKERFILE CONTENTS HERE
FROM node:20-alpine AS build

# Set working directory
WORKDIR /app

COPY package*.json ./
RUN npm install

COPY . .

RUN npm run build


FROM nginx:alpine

COPY --from=build /app/build /usr/share/nginx/html

EXPOSE 80

CMD ["nginx", "-g", "daemon off;"]
12 changes: 11 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1 +1,11 @@
# ADD DOCKER-COMPOSE CONTENTS HERE
version: "3.8"

services:
react-app:
container_name: react-app
build:
context: .
dockerfile: Dockerfile
ports:
- "8080:80"
restart: always
Binary file added prueba.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.