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
24 changes: 19 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,25 @@ Then try refreshing or opening the page again.

Like the Mac, Windows requires you to run Linux in a virtual machine, and Vagrant/Virtualbox are a great choice!

TODO:
- Other pre-requisites?
- Install vagrant and virtualbox on Windows
- Clone the repo and vagrant up
- Test
You can install VirtualBox and Vagrant via [Chocolatey](http://chocolatey.org)

```cmd
> choco install virtualbox
> choco install vagrant
```

Now you can start the environment:

```cmd
> git clone git@github.com:thehackerati/node-app-template.git
> cd node-app-template
> vagrant plugin install vagrant-docker-compose
> vagrant up
```

You'll be prompted to login using an account with admin privileges on your host machine to enable network synchronization of the source tree on your host machine with the Vagrant VM.

**Note**: Windows has a 4096 character limit on file paths. This is important to note this restriction since node_modules constantly exceed this amount. The solution is to flatten the node_modules directory (a step which is included in this codebase).

### Linux Pre-requisites

Expand Down
5 changes: 3 additions & 2 deletions app/Dockerfile.dev
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,13 @@ FROM thehackerati/node-app-template

# Install development and debugging tools
RUN npm install nodemon -g && \
npm install grunt-cli -g
npm install grunt-cli -g && \
npm install flatten-packages -g

# Use changes to package.json to force Docker not to use the cache
# when we change our application's nodejs dependencies:
ADD package.json /tmp/app/package.json
RUN cd /tmp/app && npm install
RUN cd /tmp/app && npm install && flatten-packages

WORKDIR /src/app

Expand Down