config

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Dec 20, 2017 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

///////////////////////////////////////////////////////////////////// Copyright (c) 2017 VMware, Inc. All Rights Reserved. SPDX-License-Identifier: Apache-2.0 /////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////// Copyright (c) 2017 VMware, Inc. All Rights Reserved. SPDX-License-Identifier: Apache-2.0 /////////////////////////////////////////////////////////////////////

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Identity struct {
		OIDCProvider string   `json:"oidc_provider"`
		ClientID     string   `json:"client_id"`
		ClientSecret string   `json:"client_secret"`
		RedirectURL  string   `json:"redirect_url"`
		Scopes       []string `json:"scopes"`
	} `json:"identity"`
	Openwhisk struct {
		AuthToken string `json:"auth_token"`
		Host      string `json:"host"`
	} `json:"openwhisk"`
	OpenFaas struct {
		Gateway       string `json:"gateway"`
		ImageRegistry string `json:"image_registry"`
		RegistryAuth  string `json:"registry_auth"`
	} `json:"openfaas"`
}

Config defines global configurations used in Dispatch

var Global Config

Global contains global configuration variables

func LoadConfiguration

func LoadConfiguration(file string) Config

LoadConfiguration loads configurations from a local json file

type Users

type Users struct {
	Data []struct {
		Username string `json:"username"`
		Password string `json:"password"`
	} `json:"users"`
}

Users defines a list of static users

var StaticUsers Users

StaticUsers contains a list of static users

func LoadStaticUsers

func LoadStaticUsers(file string) Users

LoadStaticUsers loads static users from a local file

Jump to

Keyboard shortcuts

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