Having trouble with something? Check out these common pitfalls.
npm packages with
Installing packages such as
sudo powers can lead to permissions
issues and ultimately to problems installing dependencies. See
for a collection of various solutions.
Installing from behind a proxy
If you're behind a proxy, you might not be able to install because Ember CLI–or
some of its dependencies–tries to
git clone a
git:// URL. (In this scenario,
http:// URLs will work).
You'll probably get an error like this:
npm ERR! git clone git://github.com/jgable/esprima.git Cloning into bare repository '/home/<username>/.npm/_git-remotes/git-github-com-jgable-esprima-git-d221af32'... npm ERR! git clone git://github.com/jgable/esprima.git npm ERR! git clone git://github.com/jgable/esprima.git fatal: unable to connect to github.com: npm ERR! git clone git://github.com/jgable/esprima.git github.com[0: 18.104.22.168]: errno=Connection timed out npm ERR! Error: Command failed: fatal: unable to connect to github.com: npm ERR! github.com[0: 22.214.171.124]: errno=Connection timed out
As a workaround you can configure
git to make the translation:
git config --global url."https://".insteadOf git://
Using Canary build instead of release
In most cases you should use a stable release, but if you need to install a canary version to test beta features, you'd do it like this:
bower install ember#canary --resolution canary
npm install --save-dev emberjs/data#master
Windows build performance issues
See The Windows Section for more details.
Cygwin on Windows
Usage with Vagrant
Vagrant is a system for automatically creating and setting up development environments that run in a virtual machine (VM).
Running your Ember CLI development environment from inside of a Vagrant VM will require some additional configuration and will carry a few caveats.
In order to access your Ember CLI application from your desktop's web browser, you'll have to open some forwarded ports into your VM. Ember CLI by default uses two ports.
- For serving assets the default is
4200. Can be configured via
- For live reload there is no default. Can be configured via
To make Vagrant development seamless these ports will need to be forwarded.
Vagrant.configure("2") do |config| # ... config.vm.network "forwarded_port", guest: 4200, host: 4200 config.vm.network "forwarded_port", guest: 9999, host: 9999 end
The way Vagrant syncs directories between your desktop and VM may prevent file watching from working correctly. This will prevent rebuilds and live reloads from working correctly. There are several workarounds:
- Watch for changes by polling the file system via:
ember serve --watcher polling.
- Use nfs for synced folders.
When setting up your VM, install Ember CLI dependencies as you normally would. Some of these dependencies (such as broccoli-sass) may have native dependencies that may require recompilation. To do so run:
The two most common Vagrant providers, VirtualBox and VMware Fusion, will both work. However, VMware Fusion is substantially faster and will use less battery life if you're on a laptop. As of now, VirtualBox will use 100% of a single CPU core to poll for file system changes inside of the VM.