MCPcopy
hub / github.com/cortexlabs/cortex / ErrorClusterAccessConfigRequired

Function ErrorClusterAccessConfigRequired

cli/cmd/errors.go:239–250  ·  view source on GitHub ↗
(cliFlagsOnly bool)

Source from the content-addressed store, hash-verified

237}
238
239func ErrorClusterAccessConfigRequired(cliFlagsOnly bool) error {
240 message := ""
241 if cliFlagsOnly {
242 message = "please provide the name and region of the cluster using the CLI flags (e.g. via `--name` and `--region`)"
243 } else {
244 message = fmt.Sprintf("please provide a cluster configuration file which specifies `%s` and `%s` (e.g. via `--config cluster.yaml`) or use the CLI flags to specify the cluster (e.g. via `--name` and `--region`)", clusterconfig.ClusterNameKey, clusterconfig.RegionKey)
245 }
246 return errors.WithStack(&errors.Error{
247 Kind: ErrClusterAccessConfigRequired,
248 Message: message,
249 })
250}
251
252func ErrorShellCompletionNotSupported(shell string) error {
253 return errors.WithStack(&errors.Error{

Callers 1

Calls 1

WithStackFunction · 0.92

Tested by

no test coverage detected