Skip to content

Running on AWS EC2

Doyub Kim edited this page Dec 3, 2016 · 2 revisions

Running Jet on AWS EC2 shouldn't be different from doing it on a local machine. So far, the Ubuntu 16.04 instance + c4.xlarge is tested (this list should grow) and works generally well with the latest.

One minor issue would be the uncaught exception when running bin/render_manual_tests_output script to generate images from manual tests for human validation. The out-of-the-box configuration of the instance will complain about the display setting, which is kind of obvious given that it is a headless cloud instance, and the solution for this issue is quite simple.

First, run the following command to locate where the matplotlibrc is placed.

python -c "import matplotlib; print matplotlib.matplotlib_fname()"

It will print out the file path to the terminal, such as:

/home/ubuntu/.local/lib/python2.7/site-packages/matplotlib/mpl-data/matplotlibrc

Edit the matplotlibrc file and change the backend to agg, such as:

# The default backend; one of GTK GTKAgg GTKCairo GTK3Agg GTK3Cairo
# CocoaAgg MacOSX Qt4Agg Qt5Agg TkAgg WX WXAgg Agg Cairo GDK PS PDF SVG
# Template.
# You can also deploy your own backend outside of matplotlib by
# referring to the module name (which must be in the PYTHONPATH) as
# 'module://my_backend'.
backend      : agg

This will allow you to render the test output as normal. For more details about the matplotlibrc, checkout http://matplotlib.org/users/customizing.html

Clone this wiki locally