Initial commit: Open sourcing all of the Maple Open Technologies code.
This commit is contained in:
commit
755d54a99d
2010 changed files with 448675 additions and 0 deletions
32
cloud/maplefile-backend/cmd/wire-test/main.go
Normal file
32
cloud/maplefile-backend/cmd/wire-test/main.go
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
package main
|
||||
|
||||
import (
|
||||
"log"
|
||||
"os"
|
||||
|
||||
"codeberg.org/mapleopentech/monorepo/cloud/maplefile-backend/app"
|
||||
"codeberg.org/mapleopentech/monorepo/cloud/maplefile-backend/config"
|
||||
)
|
||||
|
||||
func main() {
|
||||
// Load configuration
|
||||
cfg, err := config.Load()
|
||||
if err != nil {
|
||||
log.Fatalf("Failed to load configuration: %v", err)
|
||||
os.Exit(1)
|
||||
}
|
||||
|
||||
// Initialize application using Wire
|
||||
application, err := app.InitializeApplication(cfg)
|
||||
if err != nil {
|
||||
log.Fatalf("Failed to initialize application: %v", err)
|
||||
os.Exit(1)
|
||||
}
|
||||
|
||||
// Start the application
|
||||
log.Println("Starting MapleFile Backend with Wire DI...")
|
||||
if err := application.Start(); err != nil {
|
||||
log.Fatalf("Application failed: %v", err)
|
||||
os.Exit(1)
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue