policefeed

command module
v0.0.0-...-d2d5c45 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 16, 2022 License: MIT Imports: 5 Imported by: 0

README

Swedish Police Feed

Police events service based on Swedish RSS feeds.

Running the server

Install the binary:

go install github.com/sebnyberg/policefeed

The service uses Postgres for persistence. Provide Postgres credentials either as CLI flags, or as Postgres Environment Variables.

For CLI options, run:

policefeed server --help

Example running Postgres on localhost:

policefeed server \
  --addr localhost:8080 \
  --pgdb dev \
  --pgpassword secretpassword \
  --pghost localhost \
  --pgport 5432 \
  --pgsslmode disable \
  --pguser myuser

Development

Start the Postgres database with Docker-Compose

docker-compose up -d

Run the server

go run main.go server

As per the Police website:

Du får använda våra RSS-flöden på din egen webbplats under förutsättning att det tydligt framgår att polisen är källan och att du länkar till artikeln på polisen.se. Det är inte tillåtet att använda polisens logotyp.

Or in English:

You may use our RSS-feeds in your own application given that it is made clear that the police is the source, and that the article at polisen.se is linked to. It is forbidden to use the police logo.

As per the MIT license, I waive any liability in the event that you misuse this software. The default configuration should be conservative enough to avoid undue pressure on the Police's servers.

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
cmd
feedfakes
Code generated by counterfeiter.
Code generated by counterfeiter.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL