cmd

package
v0.0.0-...-941b294 Latest Latest
Warning

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

Go to latest
Published: May 19, 2022 License: MIT Imports: 36 Imported by: 0

Documentation

Index

Constants

View Source
const VERSION = "3.12.5"

Variables

View Source
var (
	TemplateFs embed.FS
)

Functions

func Execute

func Execute()

Execute adds all child commands to the root command and sets flags appropriately. This is called by main.main(). It only needs to happen once to the rootCmd.

func IDTokenTokenSource

func IDTokenTokenSource(ctx context.Context) (oauth2.TokenSource, error)

func NewServerConnection

func NewServerConnection(ctx context.Context, host string) (*grpc.ClientConn, error)

NewServerConnection creates a new gRPC connection to one of alis_ services.

The host should be the domain where the Service is hosted,: Format: v1.{neuron}.{resources|services}.{deployment-project}.{domain}.alis.dev

Best practise is to create a new connection at global level, which could be used to run many methods. This avoids unnecessary api calls to retrieve the required ID tokens each time a single method is called.

Types

type GoMod

type GoMod struct {
	Module struct {
		Path string `json:"Path"`
	} `json:"Module"`
	Go      string `json:"Go"`
	Require []struct {
		Path     string `json:"Path"`
		Version  string `json:"Version"`
		Indirect bool   `json:"Indirect,omitempty"`
	} `json:"Require"`
	Exclude []struct {
		Path    string `json:"Path"`
		Version string `json:"Version"`
	} `json:"Exclude"`
	Replace []struct {
		Old struct {
			Path string `json:"Path"`
		} `json:"Old"`
		New struct {
			Path string `json:"Path"`
		} `json:"New"`
	} `json:"Replace"`
	Retract []struct {
		Low  string `json:"Low"`
		High string `json:"High"`
	} `json:"Retract"`
}

GoMod represents content in a go.mod file.

type Parameters

type Parameters struct {
	Organisation string
	Product      string
	Contract     string
	Neuron       string
	VersionMajor string
}

Jump to

Keyboard shortcuts

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