Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FetchTLSCertificate ¶
FetchTLSCertificate will use the ACME protocol and LetsEncrypt to download a certificate to the user's cache dir automatically. This either needs rights to bind :80 (i.e. sudo) or the right capabilities (i.e. sudo setcap CAP_NET_BIND_SERVICE=+ep ~/go/bin/brig)
func UserCacheDir ¶
UserCacheDir is the same as os.UserCacheDir from go1.11, but taken from the standard library. This way it also works for go1.9 and go1.10.
This method should be replaced by os.UserCacheDir by go1.13.
Types ¶
type Gateway ¶
type Gateway struct {
// contains filtered or unexported fields
}
Gateway is a small HTTP server that is able to serve files from brig over HTTP. This can be used to share files inside of brig with users that do not use brig.
func NewGateway ¶
func NewGateway(fs *catfs.FS, rapi remotesapi.RemotesAPI, cfg *config.Config, ev *events.Listener, dbPath string) (*Gateway, error)
NewGateway returns a newly built gateway. This function does not yet start a server.
func (*Gateway) Start ¶
func (gw *Gateway) Start()
Start will start the gateway. If the gateway is not enabled in the config, this does nothing. The gateway is started in the background, this method does not block.
func (*Gateway) UserDatabase ¶ added in v0.4.0
func (gw *Gateway) UserDatabase() *db.UserDatabase
UserDatabase returns the user database API.
Directories ¶
Path | Synopsis |
---|---|
Package remotesapi implements a simple API for accessing all remotes and their online state as well as triggering syncs and diffs.
|
Package remotesapi implements a simple API for accessing all remotes and their online state as well as triggering syncs and diffs. |
Package static contains embedded resources
|
Package static contains embedded resources |
Package templates contains embedded resources
|
Package templates contains embedded resources |