summaryrefslogtreecommitdiff
path: root/main.go
diff options
context:
space:
mode:
authorxengineering <me@xengineering.eu>2023-02-12 19:18:48 +0100
committerxengineering <me@xengineering.eu>2023-02-12 19:18:48 +0100
commit88af7a818f2ef3c45c4e849512ca1f6289a9dce2 (patch)
tree878a6feec224c6169ebee15487e80f6ce27224d2 /main.go
parenta288826b924266ff4577003103ef49cf6bb5cc3c (diff)
downloadceres-88af7a818f2ef3c45c4e849512ca1f6289a9dce2.tar
ceres-88af7a818f2ef3c45c4e849512ca1f6289a9dce2.tar.zst
ceres-88af7a818f2ef3c45c4e849512ca1f6289a9dce2.zip
Centralize templating
This makes templating easier and allows to use partial templates.
Diffstat (limited to 'main.go')
-rw-r--r--main.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/main.go b/main.go
index bdea383..483633c 100644
--- a/main.go
+++ b/main.go
@@ -6,14 +6,17 @@ import (
"os"
"os/signal"
"syscall"
+ "text/template"
)
var config RuntimeConfig
var db *sql.DB
+var templates *template.Template
func main() {
log.Printf("Started Ceres recipe server.\n")
config = GetRuntimeConfig()
+ templates = setupTemplates()
db = setupDatabase()
provideShutdown()
runServer()