Files
wallet/backend/server/configure.go
T
wt 547949795f
Build and Test / build-and-test-backend (push) Successful in 27s
Build and Test / build-and-test-frontend (push) Successful in 32s
added routes package and serve in server package
2025-08-10 15:09:09 +07:00

26 lines
510 B
Go

package server
import (
"backend/api"
"backend/database"
"backend/routes"
"backend/utils"
"github.com/gofiber/fiber/v2"
"github.com/gofiber/fiber/v2/log"
)
func Configure(app *fiber.App) {
utils.LoadEnv("wallet.conf")
database.InitDatabase()
log.SetLevel(log.LevelDebug)
app.Static("/", "../frontend/build")
apiGroup := app.Group("/api")
apiGroup.Post("/token", api.Login)
InitMiddlewares(app)
routes.UsersRoutes(apiGroup)
routes.OperationRoutes(apiGroup)
routes.CategoryRoutes(apiGroup)
}