- Run (on Linux)
sudo apt-get install libsndfile portaudio aplay
. - Run
bundle install
.
- Run
ruby index.rb
to start the Sinatra server (served at localhost:4567).
The Raspberry PI is running an apache2
server. The main config file is located at /etc/apache2/apache2.conf
.
The Sinatra
roomba server runs on port 4567
be default. We wanted to enable access to the server through port 80, simply by typing roomba.local
in the browser address bar. In order to do that, we added a reverse proxy configuration to apache:
- Installed a revesre proxy module via
a2enmod proxy_http
(see this link). - We created
/etc/apache2/sites-available/roomba
. - We created a symlink to that file:
/etc/apache2/sites-enabled/roomba
. - We removed all other symlinks from
/etc/apache2/sites-enabled/
, so that they don't collide with our reverse proxy configuration. - Then we restarted apache by calling
sudo /etc/init.d/apache2 restart
.