Add scaffolding for scope package

This commit is contained in:
David Stotijn
2020-10-01 21:46:35 +02:00
parent 46caa05d20
commit d48f1f058d
7 changed files with 177 additions and 12 deletions

View File

@ -14,6 +14,7 @@ import (
"github.com/dstotijn/hetty/pkg/db/cayley"
"github.com/dstotijn/hetty/pkg/proxy"
"github.com/dstotijn/hetty/pkg/reqlog"
"github.com/dstotijn/hetty/pkg/scope"
"github.com/99designs/gqlgen/graphql/handler"
"github.com/99designs/gqlgen/graphql/playground"
@ -64,7 +65,11 @@ func main() {
}
defer db.Close()
reqLogService := reqlog.NewService(db)
scope := scope.New(nil)
reqLogService := reqlog.NewService(reqlog.Config{
Scope: scope,
Repository: db,
})
p, err := proxy.NewProxy(caCert, caKey)
if err != nil {