Preparing your Windows box for AWS and a MEAN (Node) website: Setup your MEAN.js website

Joseph Nielsen
4 min readSep 16, 2016

--

I walk through step by step how to get the Node.JS MEAN.JS scaffolded site working on a Windows 10 machine. This section is where you use the Yeoman (yo) code generator tool to create a template MEAN.JS website.

Building our MEANJS scaffold website

Let’s go back to the c: drive in our bash window.

Open a new Git Bash window and type

cd c:

Let’s make a directory for our work and then navigate to that directory.

mkdir projectscd projects

We’ll make a directory for our website, and call it “awesomewebsite”. Because, it’s awesome.

mkdir awesomewebsitecd awesomewebsite
I’m working within the folder /c/projects/awesomewebsite

Let’s setup our scaffold site now.

yo meanjs

If you want to skip running npm install during install, use this parameter: yo meanjs --skip-install

I hit the down arrow key twice, even though I can’t see the cursor move. We are working with 0.4.2 in this example.

If you like, instead of hitting down arrow, hit enter to work with the latest version 0.5-beta on master.

I type in my website folder name, because the word awesome reminds me of “thedude”

or just hit enter to everything and accept defaults

The questions go on. You can either hit enter to all of them or enter your own words. Here are my responses as demonstrated above.

What mean.js version would you like to generate? 0.4.2 (down arrow twice)
In which folder would you like the project to be generated? thedude
What would you like to call your application? thedude
How would you describe your application? Stack JavaScript with MongoDB (these are for search keywords)
What is your company/author name? CodingJoe
Would you like to generate the article example CRUD module? Y
Would you like to generate the chat example module? Y

Now we wait. And wait. And wait. (if you want to skip this several minute wait next time, you can use the yo parameter “--skip-install” to skip over having yo run “npm install”.

Now let’s test this when we get back to the prompt.

finally done! you can use this delay time to setup AWS

Type this when the blinking cursor and prompt becomes available

cd thedudegrunt
If you got an error, it’s because you didn’t install Ruby and sass

If you got the error and you don’t want to install Ruby and Sass you can bypass for now by running “grunt --force”.

Make sure to grant access to the firewall if you are prompted.

click Allow access

The screen should look like this to show that you are running. (If you got a can’t connect to Mongo, did you forget to startup Mongo with mongod.exe or did you stop the service?)

now you can access the website from http://localhost:3000

Now open a browser window and go to this website

http://localhost:3000

it works. oh happy day!

Amazing, it works. Woohoo!

--

--

Joseph Nielsen

I lead the software engineering and DevOps practice for Slalom, New Jersey. I enjoy building things, endurance running and all things DeepRacer.