switch to pgx driver + create merch

This commit is contained in:
nquidox 2026-03-04 17:02:11 +03:00
parent 546fe13107
commit 97f8d27430
13 changed files with 289 additions and 69 deletions

View file

@ -2,18 +2,19 @@ package main
import (
"context"
log "github.com/sirupsen/logrus"
"merch-api/config"
_ "merch-api/docs"
"merch-api/internal/app"
"os"
"os/signal"
"syscall"
log "github.com/sirupsen/logrus"
)
// @Title Merch API
// @Version 2.3
// @Description Stores data about merch and prices
// @Version 2.3
// @Description Stores data about merch and prices
// @BasePath /api/v2
func main() {
ctx, cancel := signal.NotifyContext(context.Background(), os.Interrupt, syscall.SIGTERM)
@ -22,7 +23,7 @@ func main() {
cfg := config.NewConfig()
config.LogSetup(cfg.App.Mode, cfg.App.LogLvl)
appl := app.New(cfg)
appl := app.New(ctx, cfg)
if err := appl.Run(ctx); err != nil {
log.Fatal(err)