Skip to content

Getting started

Prerequisites

Dependency Version
Go 1.26+
PostgreSQL 15 – 17
TABULA Excel workbook tabula-calculator.xlsx

The Excel workbook is available from episcope.eu. Place it in the data/ directory before running build_db.

Configuration

Copy .env.example to .env and fill in your values:

cp .env.example .env
Variable Description Default
DB_HOST PostgreSQL host localhost
DB_PORT PostgreSQL port 5432
DB_USER Database user postgres
DB_PASSWORD Database password — required, no default
DB_NAME Database name ignis
DB_SSL_MODE TLS mode (require / disable) require
ALLOWED_ORIGINS Comma-separated list of allowed CORS origins — unset rejects all cross-origin requests

ALLOWED_ORIGINS

Only needed when a browser-based client calls ignis directly. For server-to-server calls (the intended deployment model), leave it unset.

DB_SSL_MODE

Use disable only for local development against a database on the same machine. Set require in all other environments.

Build

go build -o bin/app       cmd/app/main.go
go build -o bin/build_db  cmd/build_db/main.go
go build -o bin/validate  cmd/validate/main.go

Load the database

Loads the TABULA workbook into PostgreSQL. This is destructive — it drops and recreates the tabula schema.

./bin/build_db

Run the API

./bin/app   # starts on :8080

Validate

Runs the full 17-level pipeline against every row in the database and checks that the result stays within ±2% of the TABULA reference value.

./bin/validate

See the validation report for current results.

Deployment

ignis is a microservice — it should run on a private Docker network with no public port exposed. The parent application (e.g. EnerPlanET) proxies requests to it. Authentication and rate limiting are the parent application's responsibility.

Do not expose ignis directly to the internet

The API has no authentication. Restrict network access at the infrastructure level.