argo

package
v0.0.0-...-2798f75 Latest Latest
Warning

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

Go to latest
Published: Aug 8, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ResetInstance

func ResetInstance()

We need to change api instance after after regeneration argocd token

Types

type ApplicationResource

type ApplicationResource struct {
	Name      string      `json:"name"`
	Kind      string      `json:"kind"`
	Namespace string      `json:"namespace"`
	Status    string      `json:"status"`
	Health    argo.Health `json:"health"`
}

type ArgoAPI

type ArgoAPI interface {
	GetApplicationsWithCredentialsFromStorage() ([]argoSdk.ApplicationItem, error)
	GetResourceTree(applicationName string) (*argoSdk.ResourceTree, error)
	GetResourceTreeAll(applicationName string) (interface{}, error)
	GetManagedResources(applicationName string) (*argoSdk.ManagedResource, error)
	GetProjectsWithCredentialsFromStorage() ([]argoSdk.ProjectItem, error)
	GetApplication(application string) (map[string]interface{}, error)
	CheckToken() error
	GetClusters() ([]argoSdk.ClusterItem, error)
	GetApplications() ([]argoSdk.ApplicationItem, error)
	GetRepositories() ([]argoSdk.RepositoryItem, error)
	CreateDefaultApp() error
}

ArgoAPI responsible for proxy calls for argosdk that implement argo api

func GetInstance

func GetInstance() ArgoAPI

GetInstance build and provide as singleton new instance of ArgoAPI interface

type ManagedResourceState

type ManagedResourceState struct {
	Spec     ManagedResourceStateSpec
	Metadata ManagedResourceStateMetadata
	Status   ManagedResourceStateStatus
}

type ManagedResourceStateMetadata

type ManagedResourceStateMetadata struct {
	Uid string
}

type ManagedResourceStateSpec

type ManagedResourceStateSpec struct {
	Replicas int64
	Template ManagedResourceStateTemplate
}

type ManagedResourceStateStatus

type ManagedResourceStateStatus struct {
	Replicas           int64
	ReadyReplicas      int64
	UpdatedReplicas    int64
	UnavaiableReplicas int64
}

type ManagedResourceStateTemplate

type ManagedResourceStateTemplate struct {
	Spec ManagedResourceTemplateSpec
}

type ManagedResourceTemplateContainer

type ManagedResourceTemplateContainer struct {
	Image string
}

type ManagedResourceTemplateSpec

type ManagedResourceTemplateSpec struct {
	Containers []ManagedResourceTemplateContainer
}

type UnauthorizedApi

type UnauthorizedApi interface {
	GetApplications(token string, host string) ([]argoSdk.ApplicationItem, error)
	GetToken(username string, password string, host string) (string, error)
	GetVersion(host string) (string, error)
}

func GetUnauthorizedApiInstance

func GetUnauthorizedApiInstance() UnauthorizedApi

GetUnauthorizedApiInstance build and provide singleton for unathorized argo api

Jump to

Keyboard shortcuts

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