config

package
v0.0.0-...-808fada Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 11, 2020 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoadConfig

func LoadConfig(s *Server, path string)

LoadConfig loads the config

Types

type DBConfig

type DBConfig struct {
	ConnectionString string `default:"boat.db"`
	Dialect          string `default:"sqlite3"`
}

DBConfig Config for the database

type Server

type Server struct {
	SiteName       string `default:"SocialBoat"`
	TagLine        string `default:""`
	AssetsDir      string `default:"assets"`
	DBConfig       DBConfig
	RootURL        string `default:"http://localhost:8080"` // With Protocol, include port if your reverse proxy has your site on a non-standard port (80/443)
	Port           int    `default:"8080"`                  // Port the Go server will run on (enables you to run multiple instances on the same server)
	RendererConfig services.RendererConfig
	SessionSecret  string `required:"true"`
	Migrate        bool   `default:"false"`
	MigrateUp      bool   `default:"true"`
}

Server our server

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL