summaryrefslogtreecommitdiff
path: root/main.go
blob: 11cbf7cc8bd231280ae4f3dcd2ea312549a57283 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23

package main

import (
	"log"
)

var config RuntimeConfig

func main() {

	// read all sources of runtime configuration (e.g. CLI flags and config file)
	config = GetRuntimeConfig()

	// print start message
	log.Printf("Starting ceres with config file '%s'\n", config.Path)

	// initialize database
	db := InitDatabase(config.Database)

	// start web server
	runServer(config.Http, &db)
}