Skip to content

Instantly share code, notes, and snippets.

@Trshant
Last active October 4, 2019 06:54
Show Gist options
  • Save Trshant/2cc6cf99749c979b8a1be5e39b45f757 to your computer and use it in GitHub Desktop.
Save Trshant/2cc6cf99749c979b8a1be5e39b45f757 to your computer and use it in GitHub Desktop.
React Scaffolding files
version: '3'
services:
create_env:
image: "create_env"
build:
context: .
volumes:
- ./code:/code
<project-name>:
build:
context: .
dockerfile: reactlearn.Dockerfile
ports:
- 3000:3000
volumes:
- ./code:/code
FROM node:12.10.0-alpine
RUN npm install -g create-react-app \
create-react-native-app \
react-native-cli
RUN mkdir /code
WORKDIR /code
ADD . /code
FROM node:12.10.0-alpine
RUN mkdir -p /code
ADD ./code/ /code
WORKDIR /code/<project-name>
RUN npm install -g -s --no-progress yarn
CMD ["yarn", "start"]
EXPOSE 3000
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment