Idea Town is an opt-in platform that allows us to perform controlled tests of new high-visibility product concepts in the general release channel of Firefox.
Idea Town is not intended to replace trains for most features, nor is it a test bed for concepts we do not believe have a strong chance of shipping in general release. Rather, it is reserved for features that require user feedback, testing, and tuning before they ship with the browser.
- idea-town - Idea Town server and front-end
- idea-town-splash - Teaser site for collecting emails
- idea-town-addon - Idea Town add-on
- Wiki: https://wiki.mozilla.org/Idea_Town
- IRC: #ideatown on irc.mozilla.org
-
Make sure you have a default Docker machine:
docker-machine create -driver virtualbox default
- Make sure your shell can see the default Docker machine:
eval "$(docker-machine env default)"
- Check the IP address of the default Docker machine:
docker-machine ip default
- Add an entry for
ideatown.dev
in your/etc/hosts
pointing to the Docker machine IP
192.168.99.100 ideatown.dev
This entry is necessary to support Firefox Accounts
- Create and setup the Docker containers:
docker-compose up
this may take some time
- Visit the Django server:
open http://ideatown.dev:8000/
you can also use whatever IP was reported by docker ip
with port 8000
-
To shell into one of the containers, e.g. to run Django commands:
docker exec -t -i ideatown_server_1 bash
-
If you change
package.json
to add dependencies forgulpfile.js
, you must rebuildclient_build
:docker-compose build client_build
-
If you change
requirements.txt
to add dependencies for Django, you must rebuildserver
:docker-compose build server
-
Sometimes the database container hasn't fully started when the Django container wants to connect to it. If this happens:
docker ps
to get the name of the Django container (something likeideatown_server_1
)docker restart ideatown_server_1
to restart the Django container
There's a sample test in idea_town/base/tests.py
for your convenience, that
you can run using the following command:
python manage.py test
If you want to run the full suite, with flake8 and coverage, you may use tox. This will run the tests the same way they are run by travis):
pip install tox
tox
The .travis.yml
file will also run coveralls by
default.
-
Add your project in Docker Registry as Automated Build
-
Prepare a 'env' file with all the variables needed by dev, stage or production.
-
Run the image:
docker run --env-file env -p 80:8000 mozilla/idea-town
- heroku create
- heroku config:set DEBUG=False ALLOWED_HOSTS=.herokuapp.com, SECRET_KEY=something_secret DATABASE_URL gets populated by heroku once you setup a database.
- git push heroku master
A newrelic.ini file is already included. To enable NewRelic monitoring add two enviroment variables:
- NEW_RELIC_LICENSE_KEY
- NEW_RELIC_APP_NAME