Stadtratmonitor – Frontend https://stadtratmonitor.leipzig.codefor.de
Find a file
Jörg Reichert 72537be348 Merge pull request #35 from joergreichert/12-seq-papers
12: Group sequential papers in search results
2017-01-01 14:23:13 +01:00
app #12 - fixed rspec tests and add some more tests 2017-01-01 13:41:28 +01:00
bin Add bin/run-tests script to run the tests 2016-05-04 21:00:33 +02:00
config / as root 2016-04-10 20:32:49 +02:00
db Add paper_searches table 2015-11-23 22:10:45 +01:00
lib Used fixed scraper implementation 2016-04-03 08:01:08 +02:00
log Start with a Rails app with authentication via Persona, Foundation CSS 2014-11-19 18:48:28 +01:00
public Start with a Rails app with authentication via Persona, Foundation CSS 2014-11-19 18:48:28 +01:00
spec #12 - fixed rspec tests and add some more tests 2017-01-01 13:41:28 +01:00
test simplify routes 2016-04-10 14:48:04 +02:00
vendor/assets Start with a Rails app with authentication via Persona, Foundation CSS 2014-11-19 18:48:28 +01:00
.coveralls.yml readded after_success call 2016-03-05 21:54:04 +01:00
.dockerignore Add Dockerfile and docker-compose config 2016-01-23 20:33:02 +01:00
.gitignore gitignore node_modules 2016-05-04 20:56:57 +02:00
.project added .travis.yml 2016-03-02 20:05:12 +01:00
.rspec add rspec config 2016-02-17 07:58:57 +01:00
.ruby-version Start with a Rails app with authentication via Persona, Foundation CSS 2014-11-19 18:48:28 +01:00
.travis.yml Update travis config to use run-tests script 2016-05-04 22:41:45 +02:00
config.ru Start with a Rails app with authentication via Persona, Foundation CSS 2014-11-19 18:48:28 +01:00
docker-compose.yml add env variables when running rspec 2016-03-05 23:24:36 +01:00
Dockerfile Replace phantomjs with capybara-webkit for headless testing 2016-05-04 20:56:02 +02:00
Gemfile Updated gems 2016-05-04 22:23:42 +02:00
Gemfile.lock Updated gems 2016-05-04 22:23:42 +02:00
Guardfile Add guard file watcher 2016-02-18 08:41:45 +01:00
LICENSE Initial commit 2014-11-19 17:03:06 +01:00
Rakefile Start with a Rails app with authentication via Persona, Foundation CSS 2014-11-19 18:48:28 +01:00
README.md Add Gemnasium badge to README 2016-05-04 23:12:50 +02:00

Stadtratmonitor

Build Status Coverage Status Code Climate Dependency Status

Offical site: https://stadtratmonitor.leipzig.codefor.de/

Usage / Features

The Stadtratmonitor Leipzig is a lightweight user interface for performing full text searches against paper contents issued to the city council of Leipzig. Note, this solution uses the data from Ratsinformationssystem Leipzig that also offers text search capabilities.

Sorting

  • Sort by date, paper was issued

Papers sorted by publishing date

  • Sort by relevance, e.g. how often the search keyword appears inside the title resp. the content of the paper

Papers sorted by relevance

Filtering

  • By paper type

Filter by paper type

  • By originator

Filter by originator

Staying up-to-date

General

Example using Firefox and RSSOWL

Click on the newsfeed icon in the address bar Abonnieren mit Firefox

Copy the URL from the address bar RSS URL in Firefox

Create a new Feed in RSSOWL and paste the just copied URL in the form RSSOWL Feed

When updating the feed in RSSOWL (or any other RSS reader of your choice) time after time all new papers matching the search query criteria will appear.

Setup

There are two ways to run this app: using a local development setup, or using docker.

Local machine setup

  1. Install Ruby, Bundler, Elasticsearch
  2. Start Elasticsearch: elasticsearch
  3. Setup Rails app: bundle && bundle exec rake db:setup
  4. See "Importing data" below
  5. Start Rails server: bundle exec rails s
  6. Visit http://localhost:3000

Using docker

  1. Install docker and docker-compose: https://docs.docker.com/compose/install/
  2. Start the app: docker-compose up
  3. Initialize the database: docker-compose run web rake db:setup
  4. See "Importing data" below
  5. Get the address of the docker host: docker-machine ip default
  6. Point your browser to: 'http://<IP of docker host>:3000'

Importing data and building the index

  1. Currently an API key for morph is required: cp config/morph.yml.example config/morph.yml Edit the morph.yml file and insert the Morph API key
  2. Import the data from our scraper: docker-compose run web rake import_papers
  3. Build the elasticsearch index: docker-compose run web rake index:rebuild

Running tests

Assuming docker and docker-compose is installed:

  1. docker-compose run web bin/run-tests