Container of react application to run on your device, showing static content
118
Repository used: https://github.com/falconcr/react-demo
FROM node:17-alpine
WORKDIR /app
COPY package.json .
RUN npm install
COPY . .
EXPOSE 3000
CMD ["npm", "start"]
version: "3.8"
services:
react-demo:
build: ./react-demo
container_name: react-demo-containerized
ports:
- '3000:3000'
stdin_open: true
tty: true
docker pull node:17-alpine
Once everything has been setup as described above, you can finally build up your own react dockerized application.
docker compose up -d
If you want to test this application on your end, follow the next steps:
docker pull kennethsv1821/docker_challenge_1-react-demo
docker run -d -p 3000:3000 --name react-test kennethsv1821/docker_challenge_1-react-demo
Once it started to run, you can access the application by going to a Web Browser and navigate to the following URL: http://localhost:3000
Content type
Image
Digest
sha256:d15855d6d…
Size
181.2 MB
Last updated
over 2 years ago
docker pull kennethsv1821/docker_challenge_1-react-demo