Dockerfile for Yeoman with React generators
Install Docker Machine.
Create virtual machine:
docker-machine create -d virtualbox dev
Get IP address:
docker-machine ip dev
Connect to virtual machine:
docker-machine ssh dev
Go to shared (between host and virtualbox) home directory:
cd /Users/<MAC USER>
cd /c/Users/<WINDOWS USER>
Run alexagency/react-yeoman container from Docker Hub:
docker run -it --rm -p 3000:3000 -p 3001:3001 -v $(pwd)/react:/app alexagency/react-yeoman
Initiate one of Yeoman generators:
yo react-fullstack
yo react-static
yo react-webpack
Check generated project:
/Users/<MAC USER>/react
/c/Users/<WINDOWS USER>/react
Install Node.js components:
npm install
Run unit tests:
npm test
Compile and launch:
npm start
Browse to React webapp:
React Starter Kit and React Static Boilerplate:
http://<virtual machine ip>:3000/
http://<virtual machine ip>:3001/