AngularJS on Ubuntu VM

Installing npm on Ubuntu

I wanted to get started with this AngularJS tutorial, and I wanted to set up my environment to do so on an Ubuntu virtual machine.

As I ran through the process of setting up the VM and installing some prerequisite stuff, I ran into a couple small issues. This post will explain what it takes to get up and running quickly.

My host machine is a MacBook Pro running OS X 10.9.2. And I was installing Ubuntu 14.04 as the guest operating system (these instructions might be close to correct for Ubuntu 13.10 as well).

Here’s what I did:

At this point I noticed that Ubuntu seemed to be laggy even though I’d given it 8GB of ram. This was remedied by enabling 3D acceleration and bumping up the memory allocated for the display. Note: the virtual machine has to be stopped before these settings can be edited.

[caption id=”attachment_114” align=”alignnone” width=”1142”]Screenshot of VirtualBox display settings window Check the ‘Enable 3D Acceleration’ checkbox[/caption]

I also installed the guest additions from the VirtualBox Device menu. After restarting the Guest OS I was able to run Ubuntu in full screen.

Now I was ready to install Git, Nodejs, and npm.