4.2 KiB
Stadtratmonitor
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
- Sort by relevance, e.g. how often the search keyword appears inside the title resp. the content of the paper
Filtering
- By paper type
- By originator
Staying up-to-date
General
- Subscribing
- Google Chrome RSS extension
- Firefox RSS extension
- Reading
- Google Chrome Extension
- Firefox Extension
- RSSOWL
Example using Firefox and RSSOWL
Click on the newsfeed icon in the address bar
Copy the URL from the address bar
Create a new Feed in RSSOWL and paste the just copied URL in the form
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
- Install Ruby, Bundler, Elasticsearch
- Start Elasticsearch:
elasticsearch
- Setup Rails app:
bundle && bundle exec rake db:setup
- See "Importing data" below
- Start Rails server:
bundle exec rails s
- Visit http://localhost:3000
Using docker
- Install docker and docker-compose: https://docs.docker.com/compose/install/
- Start the app:
docker-compose up
- Initialize the database:
docker-compose run web rake db:setup
- See "Importing data" below
- Get the address of the docker host:
docker-machine ip default
- Point your browser to: 'http://<IP of docker host>:3000'
Importing data and building the index
- 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 - Import the data from our scraper:
docker-compose run web rake import_papers
- Build the elasticsearch index:
docker-compose run web rake index:rebuild
Running tests
Assuming docker and docker-compose is installed:
docker-compose run web bin/run-tests