aun-subscreen: the kaigi subscreen system
aun-subscreen is a re-implementation of a subset of aun. aun is the kaigi signage system, which was operated at RubyKaigi 2013. Since aun has lots of "RubyKaigi" specific features, it is too much for regular purpose.
aun-subscreen is just for "subscreen", which gives a timeline view of tweets and IRC messages. By keeping the scope small, the deployment becomes much more simple. We, team aun, hope to see aun energizes the communication in many conferences!
Deployment to Heroku
or Setup as below
$ heroku create [Your Application Name]
Set environment variables
See documents for detail.
$ heroku addons:add heroku-postgresql:dev --version=9.3 Adding heroku-postgresql:dev on aun-subscreen... done, v4 (free) Attached as HEROKU_POSTGRESQL_AMBER_URL Database has been created and is available ! This database is empty. If upgrading, you can transfer ! data from another database with pgbackups:restore. Use `heroku addons:docs heroku-postgresql` to view documentation.
Make sure to add
--version=9.3 option. The part
HEROKU_POSTGRESQL_AMBER_URL may vary.
$ heroku pg:promote HEROKU_POSTGRESQL_AMBER_URL Promoting HEROKU_POSTGRESQL_AMBER_URL (DATABASE_URL) to DATABASE_URL... done
(Specify the same url as result in
git push heroku master
You need to configure
aun-subscreen with environment variables.
This is to play with PaaS deployment, such as heroku.
For development or deployment on local machines, foreman is useful to keep environment variables and
sub-subcreen to be running.
production for production.
aun-subscreen will listen on the
heroku will set this automatically.
URL to PostgreSQL.
Rough number of messages to keep in DB. This does not work exactly due to restriction of implementation. As Heroku Postgres Dev database can keep only 10,000 rows, say, 9,500 will be reasonable value including margin.
If none specified, all messages will be kept.
Periodically ping this URL if specified to keep alive. This is especially useful for deployment on heroku, since heroku gets down inactive web dynos unless more than one dynos reserved.
Twitter Receiver Configurations
If you want to receive twitter stream, you need to set these variables.
Credentials for twitter. Tokens should be concatenated with ':'.
TWITTER_AUTH=[Consumer key]:[Consumer secret]:[Access token]:[Access token secret]
Strings to track.
TWITTER_QUERYshould be comma separated
IRC Receiver Configurations
If you want to receive messages from IRC, you need to set these variables.
Hostname of the IRC server.
Port number of the IRC server.
Nick to use to connect the IRC server.
Channels to join.
IRC_CHANNELSshould be comma separated
You may want to hide some tweets from screen. This is for it. Two types of filters are available: regular expression based filter and screen name based filter.
Regexp to exclude tweets from screen.
Example (to exclude RTs):
TWITTER_EXCLUDE_REGEXPshould be a regular expression
Screen names to exclude from screen.
TWITTER_EXCLUDE_SCREEN_NAMEshould be comma separated
http://[Your Application Name].herokuapp.com with your web browser.
You will see all messages received.
You can have different views by specifying query parameters.
If you specify
?tweet=[Twitter Filtering Regexp], tweets matching with the regexp are shown.
If you specify
?irc=test, only messages on
#test channels are shown. You can provide multiple channels separating with comma. If you want to show channels
#test2, you need to specify
You can use
irc parameters in combination.
?tweet=example&irc=test will show tweets containing
example in text and messages from IRC channel