Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Firefox Accounts Content Server
JavaScript HTML CSS Shell
branch: master

Merge pull request #2629 from mozilla/convert-fx-desktop-channel

refactor(client): The FxDesktop channel is now based on the DuplexChannel. r=rfk,zaach
latest commit 6713a05b3a
@zaach zaach authored
Failed to load latest commit information.
app Merge pull request #2629 from mozilla/convert-fx-desktop-channel
docs chore(docs): Add documentation for email opt-in checkbox check/uncheck.
grunttasks chore(build): Include license header at the top of minified main.js
locale chore(l10n): update local templates
scripts fix(lint): remove "use strict" from server code
server chore(lint): replace all occurrences of global
tests chore(lint): replace all occurrences of global
.awsbox.json add static directory configuration param and fix awsbox config
.bowerrc Fixed gitignore. Added .bowerrc.
.editorconfig feat(oauth): suggest account to use during sign up if possible
.eslintignore chore(lint): switch from JSHint to ESLint
.eslintrc chore(lint): replace all occurrences of global
.gitattributes Generated basic Yeoman project.
.gitignore feat(experiments) allow able controlled feature flags
.jscsrc fix(jscs): allow the 'other' quote mark to be used, but only to avoid…
.travis.yml chore(travis): Tell Travis to use #fxa-bots
AUTHORS chore(docs): update authors file Release v0.40.0 chore(lint): remove jshint
Dockerfile feat(docker): Dockerfile and README update for basic docker developme…
Gruntfile.js chore(build): Include license header at the top of minified main.js
LICENSE Add MPL 2.0 license file. chore(lint): remove jshint
bower.json feat(avatars): add metrics for avatar cropping operations
npm-shrinkwrap.json chore(deps): bump po2json to make logging better
package.json Merge pull request #2632 from eoger/issue-2592-prepush-lint

Firefox Accounts Content Server

Build Status: Travis Coverage Status

Static server that hosts Firefox Account sign up, sign in, email verification, etc. flows.

Follow the instructions on: fxa-local-dev

The above link helps to install the following pre-requisites, and set up a development environment.


  • node 0.10.x
  • npm
  • Grunt
  • libgmp
  • fxa-local-dev - Please note that this is the preferred way of contributing to Firefox Accounts.

Development Setup

Make sure that fxa-local-dev servers are running. The fxa-content-server will listen on by default.

Note: If you have issues with npm install please update to npm 2.0+ using npm install -g npm@2 (Issue #1594)

Docker Based Development

To run the content server via Docker, three steps are required:

$ docker build --rm -t mozilla/fxa_content_server .
$ docker run --rm -v $PWD:/opt/fxa mozilla/fxa_content_server npm install
$ docker run -it --rm -v $PWD:/opt/fxa --net=host mozilla/fxa_content_server

This method shares the codebase into the running container so that you can install npm and various modules required by package.json. It then runs FxA content server in a container, while allowing you to use your IDE of choice from your normal desktop environment to develop code.

Be sure to copy server/config/local.json-dist to server/config/local.json per usual before the final docker invocation to run the service.

Note to boot2docker users: you must edit your server/config/local.json to use the correct IP of your boot2docker VM. Check with the command: boot2docker ip

Then replace the public_url IP address in local.json that reads: "public_url": "" with the IP that you noted above. It should be something like

To stop the container, first try CTRL+C. If that does not work, run docker ps |grep fxa_content_server to get the hexadecimal Container ID (the first column of output). Run docker stop nnnnnnnnnnnn where the nnnn part is the Container ID.




  • Run Selenium Server

e.g. in shell form:

java -jar selenium-server-standalone-2.46.0.jar 

To run tests locally with Selenium:

npm test

To change the default auth server edit server/config/*.json on your deployed instance.

  "fxaccount_url": ""

Note that testing with Selenium via Docker does not work at present, so all testing must be carried out via your normal operating system's npm & Java tooling.

Grunt Commands

Grunt is used to run common tasks to build, test, and run local servers.

grunt build build production resources. See task source for more documentation
grunt clean remove any built production resources.
grunt lint run ESLint, JSONLint, and JSCS (code style checker) on client side and testing JavaScript.
grunt server run a local server running on port 3030 with development resources.
grunt server:dist run a local server running on port 3030 with production resources. Production resources will be built as part of the task.
grunt test run local Intern tests.
grunt version stamp a new minor version. Updates the version number and creates a new
grunt version:patch stamp a new patch version. Updates the version number and creates a new



MPL 2.0

Something went wrong with that request. Please try again.