28 lines
357 B
Go
28 lines
357 B
Go
package config
|
|
|
|
import (
|
|
"github.com/joho/godotenv"
|
|
"os"
|
|
)
|
|
|
|
var (
|
|
ServerPort string
|
|
|
|
Address string
|
|
Path string
|
|
|
|
DatabaseFile string
|
|
FrontendDir string
|
|
)
|
|
|
|
func init() {
|
|
godotenv.Load()
|
|
|
|
ServerPort = os.Getenv("SERVER_PORT")
|
|
|
|
Address = os.Getenv("ADDRESS")
|
|
|
|
DatabaseFile = os.Getenv("DATABASE_FILE")
|
|
FrontendDir = os.Getenv("FRONTEND_DIR")
|
|
}
|