Fathom Analytics module for After Dark https://after-dark.habd.as/module/voyeur
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Josh Habdas 28a7570472
chore(package): dymamically set min after dark version
5 months ago
layouts/partials/modules/voyeur refactor(layouts): convert tabs to spaces 9 months ago
.gitignore chore: add gitignore file 8 months ago
CHANGELOG.md chore(release): 1.0.0 9 months ago
COPYING initial commit 9 months ago
README.md chore(package): dymamically set min after dark version 5 months ago
docker-compose.dev.yml initial commit 9 months ago
docker-compose.yml initial commit 9 months ago
package-lock.json chore: prep for first release 9 months ago
package.json chore(package): dymamically set min after dark version 5 months ago

README.md

Voyeur

Self-hosted analytics for After Dark. Voyeur adds support for Fathom Analytics.

Latest NPM version NPM downloads per month Minimum After Dark version

Requirements

Setup

For Voyeur to operate you must have Fathom up and running on a VPS or embedded device such as ODROID or Raspberry Pi. If your domain uses TLS you must also enable TLS on your Fathom domain for reporting to function. If you have a wildcard SSL cert on your existing domain consider hosting Fathom on a subdomain such as stats.example.com for certificate reuse.

An example Docker Compose file to run Fathom using a Postgres database has been provided to you here as a convenience. Instructions on using it are beyond the scope of this module.

Installation

  1. Copy the contents of this repository into a directory called themes/voyeur under the root your After Dark site.
  2. Add voyeur as a theme component to your After Dark site config.toml, e.g.

    theme = [
      "voyeur", # sequence before "after-dark"
      "after-dark"
    ]
    
  3. Add and specify settings for the module in your After Dark site config, e.g.

    [params.modules.voyeur]
      enabled = true # Optional, set false to disable module
      url = "https://stats.example.org" # Optional, base analytics URL
      port = "8080" # Optional, port setting
    
  4. Build and deploy your After Dark site.

For additional information please see the Fathom project.

Development

For development, install Docker on your machine:

Configure your environment to use the dev config override:

export COMPOSE_FILE=docker-compose.yml:docker-compose.dev.yml

Run docker-compose up to start the app.

License

Copyright © 2018 Josh Habdas jhabdas@protonmail.com

This work is free. You can redistribute it and/or modify it under the terms of the Do What The Fuck You Want To Public License, Version 2, as published by Sam Hocevar. See the COPYING file for more details.