config

package
v0.0.0-...-c118cec Latest Latest
Warning

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

Go to latest
Published: Jan 13, 2024 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ActivityStreams = "application/ld+json; profile=\"https://www.w3.org/ns/activitystreams\""
View Source
var AuthReq = []string{"captcha", "email", "passphrase"}
View Source
var CookieKey = GetConfigValue("cookiekey", "")
View Source
var DB *sql.DB
View Source
var DBHost = GetConfigValue("dbhost", "localhost")
View Source
var DBName = GetConfigValue("dbname", "server")
View Source
var DBPassword = GetConfigValue("dbpass", "password")
View Source
var DBPort, _ = strconv.Atoi(GetConfigValue("dbport", "5432"))
View Source
var DBUser = GetConfigValue("dbuser", "postgres")
View Source
var Domain = TP + "" + GetConfigValue("instance", "")
View Source
var InstanceName = GetConfigValue("instancename", "")
View Source
var InstanceSummary = GetConfigValue("instancesummary", "")
View Source
var Key = GetConfigValue("modkey", "")
View Source
var Log = log.New(os.Stdout, "", log.Ltime)
View Source
var MediaHashs = make(map[string]string)
View Source
var Port = ":" + GetConfigValue("instanceport", "3000")
View Source
var PostCountPerPage = 10
View Source
var Salt = GetConfigValue("instancesalt", "")
View Source
var SiteEmail = GetConfigValue("emailaddress", "") //contact@fchan.xyz
View Source
var SiteEmailNotifyTo = GetConfigValue("emailnotify", "")
View Source
var SiteEmailPassword = GetConfigValue("emailpass", "")
View Source
var SiteEmailPort = GetConfigValue("emailport", "") //587
View Source
var SiteEmailServer = GetConfigValue("emailserver", "") //mail.fchan.xyz
View Source
var SupportedFiles = []string{"image/gif", "image/jpeg", "image/png", "image/webp", "image/apng", "video/mp4", "video/ogg", "video/webm", "audio/mpeg", "audio/ogg", "audio/wav", "audio/wave", "audio/x-wav"}
View Source
var TP = GetConfigValue("instancetp", "")
View Source
var Themes []string
View Source
var TorProxy = GetConfigValue("torproxy", "") //127.0.0.1:9050

Functions

func GetConfigValue

func GetConfigValue(value string, ifnone string) string

TODO Change this to some other config format like YAML to save into a struct and only read once

Types

This section is empty.

Jump to

Keyboard shortcuts

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