camlistore.org: camlistore.org/pkg/app Index | Files

package app

import "camlistore.org/pkg/app"

Package app provides helpers for server applications interacting with Camlistore. See also https://camlistore.org/doc/app-environment for the related variables.

Index

Package Files

app.go

func Auth Uses

func Auth() (auth.AuthMode, error)

Auth returns the auth mode for the app to access Camlistore, as defined by environment variables automatically supplied by the Camlistore server host.

func Client Uses

func Client() (*client.Client, error)

Client returns a Camlistore client as defined by environment variables automatically supplied by the Camlistore server host.

func ListenAddress Uses

func ListenAddress() (string, error)

ListenAddress returns the host:[port] network address, derived from the environment, that the application should listen on.

func PathPrefix Uses

func PathPrefix(r *http.Request) string

PathPrefix returns the app's prefix on the app handler if the request was proxied through Camlistore, or "/" if the request went directly to the app.

Package app imports 8 packages (graph) and is imported by 9 packages. Updated 2018-01-21. Refresh now. Tools for package owners.