index

Angular Full-Stack Generator deployment on Windows

This is a walk through to get generator-angular-fullstack up and running on a windows machine. This walk through has been tested on:

  • Windows Vista

  • Windows 7

  • Windows 8

  • Windows Server 2008 (all builds/ updates)

  • Windows Server 2012 (all builds/ updates)

Prerequisites

Install Python

  • Download Python 2.7 from python.org/downloads

    • Install to C:\Python27 (The Default Path) **

  • After Python is installed add the path (C:\Python27\) to your Windows PATH environment variable.

    • Start > Type Environment Variables > click "Edit the System Environment Variables" > Envrionment Variables > Click "Path" > "Edit"

  • Add C:\Python27\python.exe to the very end. (Click into box and press 'End')

Install NodeJS on Windows

  • Download & Install nvm-windows.

  • Run nvm install 6.4.0 for the version of node that you want

  • Run nvm use 6.4.0 to use that version

Install IISNode

  • Install Latest Stable release of IISNode

Install IIS URL-Rewrite Module

Install MongoDB on Windows

  • Download the current stable release of MongoDB from https://www.mongodb.org/downloads and install using the "Complete" setup type and all the default options.

  • Create the MongoDB data directory

  • Create an empty folder at ex. C:\data\db.

  • MongoDB requires a directory for storing all of it's data. The default directory is C:\data\db. You can use a different directory if you prefer by specifying the "--dbpath" parameter when starting the MongoDB server (below).

  • Start the MongoDB server daemon by running mongod.exe from the command line. mongod.exe is likely located in C:\Program Files\MongoDB\Server\[MONGODB VERSION]\bin; for example for version 3.2 the following command will start MongoDB: C:\Program Files\MongoDB\Server\3.2\bin\mongod

Getting your project started

Install the generator

  • Create an empty folder for your project

  • Open a terminal and change directories to your app's directory cd c:\example

  • Run npm install -g yo gulp-cli generator-angular-fullstack

  • Run yo angular-fullstack

Move App into production

The below steps assume you have purchased a domain and have pointed your DNS to your public IP

Build and prep

  • Run the build process gulp serve:dist

  • Move your dist/ folder to your desired directory (This is where IIS will be pointed at)

  • Copy the contents of the server/ folder into your client/ folder

  • Copy down the web.config from below and place this inside your 'client' folder (save it as 'web.config')

Setup IIS (if new build in IIS)

  • Open IIS Manager (Start > Type 'IIS Manager')

  • Create your new site (Expand Server > Right click sites > 'Add Websites')

  • Enter your site's name

  • Enter the directory path to your client/ folder (C:\example\dist\client\)

  • Enter your hostname (Your a-record)

  • Leave all other defaults and click 'Ok'

Congratulations, you did it! Now go code something awesome!

Last updated

Was this helpful?