Files
chatservice_concept/main.go

23 lines
435 B
Go

package main
import (
"log"
"os"
"git.dubyatp.xyz/chat-api-server/api"
"github.com/joho/godotenv"
)
func main() {
// Initialize dotenv file
err := godotenv.Load()
if err != nil {
// Check if environment variables are defined by OS before erroring out
_, exists := os.LookupEnv("SCYLLA_CLUSTER")
if !exists {
log.Fatal("Required environment variables are not added, and no .env file was found")
}
}
api.Start()
}