This repository has been archived on 2022-11-30. You can view files and clone it, but cannot push or open issues or pull requests.
tacitus/cmd/webapp/main.go

28 lines
412 B
Go

package main
import (
"log"
"tacitus/http"
"tacitus/postgres"
"tacitus/osutil"
)
func main() {
logger := osutil.NewLogger()
logger.Utc = true
s := http.NewServer()
db := postgres.NewClient()
db.Name = "gdax"
db.User = "gdax"
db.SetLogger(logger)
if err := db.Open(); err != nil {
log.Panic(err)
}
s.Handler.TradeHandler.TradeService = db.TradeService()
defer s.Close()
s.Open()
<- s.Err
}