Types

entity

Overview

Package entity contains type definitions for Kublr.

type AWSBlockDeviceMapping

AWSBlockDeviceMapping object for instance groups

type AWSBlockDeviceMapping struct {
    // DeviceName specifies name of the device within Amazon EC2
    DeviceName *string `json:"deviceName" yaml:"deviceName"`
    // Ebs is Elastic Block Storage volume information.
    Ebs *AwsEbsVolumeSpec `json:"ebs" yaml:"ebs"`
    // NoDevice suppresses the device mapping.
    NoDevice *bool `json:"noDevice" yaml:"noDevice"`
    // VirtualName is virtual name associated with the device.
    VirtualName *string `json:"virtualName" yaml:"virtualName"`
}

type AWSInstanceGroupLocationSpecGroupTypeEnum

AWSInstanceGroupLocationSpecGroupTypeEnum defines type of Instance Group in AWS.

type AWSInstanceGroupLocationSpecGroupTypeEnum string

type AWSLocationState

AWSLocationState represents state of AWS Location.

type AWSLocationState struct {
    CloudFormationStackID    string             `json:"cloudFormationStackId" yaml:"cloudFormationStackId"`
    CloudFormationStackState string             `json:"cloudFormationStackState" yaml:"cloudFormationStackState"`
    LastStackEventID         string             `json:"lastStackEventId" yaml:"lastStackEventId"`
    FirstStackError          string             `json:"firstStackError" yaml:"firstStackError"`
    PrepareToRecreateStack   bool               `json:"prepareToRecreateStack" yaml:"prepareToRecreateStack"`
    TemplateBodyHash         string             `json:"templateBodyHash" yaml:"templateBodyHash"`
    SnapshotIDs              map[string]*string `json:"snapshotIds" yaml:"snapshotIds"`
}

type AcmeSpec

AcmeSpec is a spec for Let’s Encrypt ACME Protocol.

type AcmeSpec struct {
    // Enabled indicates if AMCE support is enabled.
    Enabled bool
    // API URL Is an Let's Encrypt endpoint to use.
    APIURL *string `json:"apiUrl,omitempty" yaml:"apiUrl,omitempty"`
    // Email is an e-mail to use for.
    Email *string
}

type AgentConfigMap

AgentConfigMap is a Kublr agent configuration flags

type AgentConfigMap map[string]interface{}

type AlertManagerLocalCentralMonitoringSpec

AlertManagerLocalCentralMonitoringSpec is a spec for AlertManager installation Deprecated kept here just for backward compatibility

type AlertManagerLocalCentralMonitoringSpec struct {
    // Enabled indicates if AlertManager is enabled.
    Enabled bool `json:"enabled" yaml:"enabled"`
}

type AlertManagerSpec

AlertManagerSpec is a spec for AlertManager installation

type AlertManagerSpec struct {
    // Enabled indicates if AlertManager is enabled.
    Enabled bool `json:"enabled" yaml:"enabled"`
}

type AppFeatureSpec

AppFeatureSpec is a spec for application controller feature in cluster.

type AppFeatureSpec struct {
    // Chart is a helm package
    Chart *Chart `json:"chart,omitempty" yaml:"chart,omitempty"`
    // Values is a helm chart values
    Values *ChartValues `json:"values,omitempty" yaml:"values,omitempty"`

    // Enabled indicates if this feature is enabled.
    Enabled bool `json:"enabled" yaml:"enabled"`
    // Namespace kubernetes namespace to which application controller will be installed.
    Namespace *string `json:"namespace,omitempty" yaml:"namespace,omitempty"`
}

type AwsApiAccessKeySpec

AwsApiAccessKeySpec defines AWS Access Key and Secret Key.

type AwsApiAccessKeySpec struct {
    AccessKeyId     string `json:"accessKeyId" yaml:"accessKeyId"`
    SecretAccessKey string `json:"secretAccessKey" yaml:"secretAccessKey"`
}

type AwsCloudWatchLogSinkSpec

AwsCloudWatchLogSinkSpec is a spec for log sink in AWS CloudWatch.

type AwsCloudWatchLogSinkSpec struct {
    // Enabled indicates if this sink is enabled.
    Enabled bool `json:"enabled" yaml:"enabled"`
}

type AwsEbsVolumeSpec

AwsEbsVolumeSpec is a spec for EBS volume.

type AwsEbsVolumeSpec struct {
    // Type specifies type of the volume. See EBS Volume Types.
    Type string `json:"type" yaml:"type"`
    // Size determines size of the volume, in GBs.
    Size int64 `json:"size" yaml:"size"`
    // Iops specifies required iops for the volume. Valiod only for Volume type with provisioned iops.
    Iops int64 `json:"iops" yaml:"iops"`
    // Encrypted flag indicates if EBS volume should be encrypted.
    Encrypted bool `json:"encrypted" yaml:"encrypted"`
    // KmsKeyId The Amazon Resource Name (ARN) of the AWS Key Management Service master key that is used to create the
    // encrypted volume, such as arn:aws:kms:us-east-1:012345678910:key/abcd1234-a123-456a-a12b-a123b4cd56ef.
    // If you create an encrypted volume and don’t specify this property, AWS CloudFormation uses the default master key.
    //+optional
    KmsKeyId string `json:"kmsKeyId" yaml:"kmsKeyId"`
    // SnapshotId is AWS Snapshot ID to create EBS volume from
    SnapshotId *string `json:"snapshotId" yaml:"snapshotId" bson:"snapshotId"`
    // DeleteOnTermination property for ASG EBS mapping volumes
    DeleteOnTermination *bool `json:"deleteOnTermination,omitempty" yaml:"deleteOnTermination,omitempty"`
}

type AwsEipAllocationPolicyEnum

type AwsEipAllocationPolicyEnum string

type AwsInstanceGroupLocationSpec

AwsInstanceGroupLocationSpec is a spec for instance group location in AWS. It maps to auto-scaling group with a launch configuration.

type AwsInstanceGroupLocationSpec struct {
    // GroupType is a type of underlying structure supporting this group.
    // Currently 'asg' and 'elastigroup' are supported;
    // default value is 'asg'
    GroupType AWSInstanceGroupLocationSpecGroupTypeEnum `json:"groupType" yaml:"groupType" bson:"groupType"`

    // SshKey is a name of AWS SSH Key Pair used to access instances in the group.
    SshKey *string `json:"sshKey" yaml:"sshKey"`

    // AvailabilityZones is list of AZs that can be used in the location.
    // If omitted, generator will automatically assign it to all available zones.
    //+optional
    AvailabilityZones   []*string        `valid:"required" json:"availabilityZones" yaml:"availabilityZones"`
    InstanceType        *string          `json:"instanceType" yaml:"instanceType"`
    OverrideImageId     *string          `json:"overrideImageId,omitempty" yaml:"overrideImageId,omitempty"`
    ImageId             *string          `json:"imageId" yaml:"imageId"`
    ImageRootDeviceName *string          `json:"imageRootDeviceName" yaml:"imageRootDeviceName"`
    RootVolume          AwsEbsVolumeSpec `json:"rootVolume" yaml:"rootVolume"`
    MasterVolume        AwsEbsVolumeSpec `json:"masterVolume" yaml:"masterVolume"`

    // MasterElbAllocationPolicy - Master ELB allocation policy - 'default' ('public' for multi-master, and 'none' for single-master), 'none', 'private',
    //'public', or 'privateAndPublic'.
    MasterElbAllocationPolicy MasterELBAllocationPolicyEnum `json:"masterElbAllocationPolicy" yaml:"masterElbAllocationPolicy"`

    // MasterEipAllocationPolicy - Master EIP allocation policy - 'default' ('none' for multi-master, and 'public' for single-master), 'none', or 'public'.
    // @deprecated use eipAllocationPolicy instead
    MasterEipAllocationPolicy AwsEipAllocationPolicyEnum `json:"masterEipAllocationPolicy" yaml:"masterEipAllocationPolicy"`

    // NodeIpAllocationPolicy is Instance IP allocation policy - 'default' (same as 'public'), 'private', or 'public'.
    NodeIpAllocationPolicy NodeIPAllocationPolicyEnum `json:"nodeIpAllocationPolicy" yaml:"nodeIpAllocationPolicy"`

    // EipAllocationPolicy Groups EIP allocation policy - 'default', 'none', or 'public'.
    //
    // 'default' means:
    // - 'none' for multi-master groups (note that master groups are always stateful)
    // - 'none' for single-master groups with nodeIpAllocationPolicy==='private'
    // - 'public' for single-master groups with nodeIpAllocationPolicy!=='private'
    // - 'none' for stateful node groups with nodeIpAllocationPolicy==='private'
    // - 'public' for stateful node groups with nodeIpAllocationPolicy!=='private'
    // - 'none' for non-stateful node groups
    //
    // Constraints:
    // - eipAllocationPolicy may not be 'public' if nodeIpAllocationPolicy==='private'
    // - eipAllocationPolicy may not be 'public' if the group is not stateful
    EipAllocationPolicy AwsEipAllocationPolicyEnum `json:"eipAllocationPolicy" yaml:"eipAllocationPolicy"`

    // InstanceMonitoring controls whether instances in this group are launched with detailed monitoring or not.
    // detailed monitoring for EC2 instances by default will be disabled
    // default value 'false'
    // Do not set omitempty flag because it affects behavior.
    InstanceMonitoring bool `json:"instanceMonitoring" yaml:"instanceMonitoring"`

    // AWS AutoScalingGroup parameters:
    //  - Cooldown
    //  - LoadBalancerNames
    //  - TargetGroupARNs
    Cooldown *string `json:"cooldown" yaml:"cooldown"`
    // LoadBalancerNames is names for load balancer
    LoadBalancerNames []*string `json:"loadBalancerNames" yaml:"loadBalancerNames"`
    // TargetGroupARNs is the Amazon Resource Name (ARN) of the target group
    TargetGroupARNs []*string `json:"targetGroupARNs" yaml:"targetGroupARNs"`

    // AWS LaunchConfiguration parameters:
    //  - BlockDeviceMappings
    //  - EbsOptimized
    //  - InstanceMonitoring
    //  - PlacementTenancy
    //  - SpotPrice
    BlockDeviceMappings []*AWSBlockDeviceMapping `json:"blockDeviceMappings,omitempty" yaml:"blockDeviceMappings,omitempty"`
    // EbsOptimized specifies whether the instance is optimized for Amazon EBS I/O
    EbsOptimized *bool `json:"ebsOptimized,omitempty" yaml:"ebsOptimized,omitempty"`

    // PlacementTenancy specifies the tenancy of the instance. It can be either default or dedicated.
    PlacementTenancy *string `json:"placementTenancy,omitempty" yaml:"placementTenancy,omitempty"`
    // SpotPrice specifies the price to bid when launching Spot Instances.
    SpotPrice *string `json:"spotPrice,omitempty" yaml:"spotPrice,omitempty"`

    /**
     * Subnet Ids
     *
     * If omitted, subnets will be created to accommodate this instance group, otherwise corresponding autoscaling group
     * will be assigned to the specified subnets.
     *
     * Subnets must be specified corresponding to each AZ in availabilityZones array, so that for example, if
     * `availabilityZones == ['us-east1a', 'us-east-1c', 'us-east-1d']` and
     * `subnetIds == ['subnet1', '', 'subnet3']`, then generator will assume that `subnet1` exist in AZ `us-east-1a`,
     * `subnet3` exists in `us-east-1d`, and it will create a new subnet in `us-east-1c`.
     *
     * Note also that if a subnet id is specified in a certain position of `subnetIds` array, a correct
     * AZ in which this subnet is located MUST also be specified in corresponding position of `availabilityZones`
     * array.
     */
    SubnetIds []*string `json:"subnetIds" yaml:"subnetIds"`

    /**
     * ExistingSecurityGroupIds are in addition to security groups specified in `securityGroupId`
     * property in `AWSLocationSpec` object.
     */
    ExistingSecurityGroupIds []*string `json:"existingSecurityGroupIds" yaml:"existingSecurityGroupIds"`

    // Elastigroup is a specification of elastigroup.
    // +optional if groupType != 'elastigroup'
    Elastigroup *ElastigroupSpec `json:"elastigroup" yaml:"elastigroup" yaml:"elastigroup"`
}

type AwsLocationSpec

AwsLocationSpec is a spec for AWS Location.

type AwsLocationSpec struct {
    // AwsApiAccessSecretRef is a reference to the secret object containing AWS access key and secret key to access this
    // location
    AwsApiAccessSecretRef *string `json:"awsApiAccessSecretRef" yaml:"awsApiAccessSecretRef"`

    // AccountId is AWS accountId
    // If omitted, it will be populated automatically based on the secret.
    // If specified, it must correspond to the account specified in the secret.
    //+optional
    AccountId *string `json:"accountId,omitempty" yaml:"accountId,omitempty"`

    // Region is AWS region
    // If omitted, it will be populated automatically based on the secret.
    //+optional
    Region *string `json:"region,omitempty" yaml:"region,omitempty"`

    //VpcID is ID of the VPC to use.
    // If omitted, a new VPC will be created, otherwise existing VPC will be used.
    //+optional
    VpcID *string `json:"vpcId,omitempty" yaml:"vpcId,omitempty"`

    // VpcCIDRBlock is an IP address range for instances in this VPC.
    //*If omitted, one of 16 standard private /16 IP ranges (172.16.0.0/16, ... , 172.31.0.0/16) will be assigned.
    //+optional
    VpcCIDRBlock *string `json:"vpcCidrBlock,omitempty" yaml:"vpcCidrBlock,omitempty"`

    // AvailabilityZones are AWS region availability zones to be used for Kubernetes cluster in this location.
    // If omitted, it will be populated automatically to all zones available for this account in this region.
    //+optional
    AvailabilityZones []*string `valid:"required" json:"availabilityZones,omitempty" yaml:"availabilityZones,omitempty"`

    // MasterCIDRBlocks See cidrBlocks property instead
    // @deprecated
    MasterCIDRBlocks []*string `json:"masterCIDRBlocks,omitempty" yaml:"masterCIDRBlocks,omitempty"`

    // NodesCIDRBlocks See cidrBlocks property instead
    // @deprecated
    NodesCIDRBlocks []*string `json:"nodesCIDRBlocks,omitempty" yaml:"nodesCIDRBlocks,omitempty"`

    // CidrBlocks is CIDR block allocation for various purpose subnets in this location.
    //
    // This replaces deprecated properties masterCIDRBlocks, nodesCIDRBlocks, and publicSubnetCidrBlocks
    //
    // CIDR blocks in the following arrays are specified according to availability zone indices.
    //
    // Availability zone index is the index of the zone in the list of all possible zones in this region, ordered in a standard
    // lexicographical order. E.g. zones 'us-east-1a', 'us-east-1c', and 'us-east-1d' have indices 0, 2, and 3 correspondingly.
    //
    // Therefore, for example, if three public masters are defined, and two masters are placed in the zone 'us-east-1b' (zone
    // index is 1) and one master is placed in the zone 'us-east-1d' (zone index is 3), then at least the following CIDRs
    // must be specified:
    //
    // masterPublic:
    //   - ''
    //   - '<cidr for master subnet in zone us-east-1b>'
    //   - ''
    //   - '<cidr for master subnet in zone us-east-1d>'
    //
    // Each value in these arrays must either be a valid CIDR or an empty string (if unused or undefined).
    //
    // Generator will use its own set of rules when trying to specify CIDR blocks that are needed but undefined in the spec.
    // It will not try to adjust these rules to accomodate user-specified CIDR's.
    //
    // Automatic CIDR generation rules on an example of 172.16.0.0/16 global CIDR:
    //  - 172.16.0.0/17 - reserved for public subnets
    //    - 172.16.0.0/20 - reserved for public master and other subnets
    //      - 172.16.0.0/23 - reserved for various non-master/auxilary public subnets
    //        - 172.16.0.0/26 - reserved
    //        - 172.16.0.64/26, ... , 172.16.1.192/26 - allocated for otherPublic (zones 0, 1, ... , 6) (7 * 64 IPs)
    //      - 172.16.2.0/23, ... , 172.16.14.0/23 - allocated for masterPublic (zones 0, 1, ... , 6) (7 * 512 IPs)
    //    - 172.16.16.0/20, ... , 172.16.112.0/20 - allocated for nodePublic (zones 0, 1, ... , 6) (7 * 16K IPs)
    //  - 172.16.128.0/17 - reserved for private subnets
    //    - 172.16.128.0/20 - reserved for private master and other subnets
    //      - 172.16.128.0/23 - reserved for various non-master/auxilary private subnets
    //      - 172.16.130.0/23, ... , 172.16.142.0/23 - allocated for masterPrivate (zones 0, 1, ... , 6) (7 * 512 IPs)
    //    - 172.16.144.0/20, ... , 172.16.240.0/20 - allocated for nodePrivate (zones 0, 1, ... , 6) (7 * 16K IPs)
    CidrBlocks AwsLocationSpecCidrBlocks `json:"cidrBlocks" yaml:"cidrBlocks"`

    // IamRoleMasterPathName is a master role path name
    IamRoleMasterPathName string `json:"iamRoleMasterPathName,omitempty" yaml:"iamRoleMasterPathName,omitempty"`

    // IamInstanceProfileMasterPathName is a master instance profile path name
    IamInstanceProfileMasterPathName string `json:"iamInstanceProfileMasterPathName,omitempty" yaml:"iamInstanceProfileMasterPathName,omitempty"`

    // IamRoleNodePathName is a node role path name
    IamRoleNodePathName string `json:"iamRoleNodePathName,omitempty" yaml:"iamRoleNodePathName,omitempty"`

    // IamInstanceProfileNodePathName is a node instance profile path name
    IamInstanceProfileNodePathName string `json:"iamInstanceProfileNodePathName,omitempty" yaml:"iamInstanceProfileNodePathName,omitempty"`
    // EnableTerminationProtection protects the AWS stack from deletion
    // this flag is used when creating a stack
    EnableTerminationProtection *bool `json:"enableTerminationProtection,omitempty" yaml:"enableTerminationProtection,omitempty" bson:"enableTerminationProtection,omitempty"`

    // SkipSecurityGroupNode flag indicates if creating default security groups should be skipped
    SkipSecurityGroupDefault *bool `json:"skipSecurityGroupDefault,omitempty" yaml:"skipSecurityGroupDefault,omitempty" bson:"skipSecurityGroupDefault,omitempty"`
    // SkipSecurityGroupNode flag indicates if creating security groups of master should be skipped
    SkipSecurityGroupMaster *bool `json:"skipSecurityGroupMaster,omitempty" yaml:"skipSecurityGroupMaster,omitempty" bson:"skipSecurityGroupMaster,omitempty"`
    // SkipSecurityGroupNode flag indicates if creating security groups of node should be skipped
    SkipSecurityGroupNode *bool `json:"skipSecurityGroupNode,omitempty" yaml:"skipSecurityGroupNode,omitempty" bson:"skipSecurityGroupNode,omitempty"`

    // ExistingSecurityGroupIds ids of existing security groups that need to be added to all instances.
    ExistingSecurityGroupIds []*string `json:"existingSecurityGroupIds,omitempty" yaml:"existingSecurityGroupIds,omitempty"`
}

type AwsLocationSpecCidrBlocks

AwsLocationSpecCidrBlocks defines CIDR block allocation for various purpose subnets in this location.

type AwsLocationSpecCidrBlocks struct {
    // MasterPublic defines CIDR blocks for subnets used for public master groups
    // +optional
    MasterPublic []string `json:"masterPublic" yaml:"masterPublic"`
    // MasterPrivate defines CIDR blocks for subnets used for private master groups
    // +optional
    MasterPrivate []string `json:"masterPrivate" yaml:"masterPrivate"`
    // NodePublic defines CIDR blocks for subnets used for public node groups
    // +optional
    NodePublic []string `json:"nodePublic" yaml:"nodePublic"`
    // NodePrivate defines CIDR blocks for subnets used for private node groups
    // +optional
    NodePrivate []string `json:"nodePrivate" yaml:"nodePrivate"`
    // OtherPublic defines CIDR blocks used for public subnets necessary for other purposes (e.g. placing NAT and bastion host in situation
    //when no other public subnets exist)
    // +optional
    OtherPublic []string `json:"otherPublic" yaml:"otherPublic"`
}

type AwsS3SecretStoreSpec

AwsS3SecretStoreSpec is a spec for secret store in Amazon S3 Bucket.

type AwsS3SecretStoreSpec struct {
    LocationRef  string `json:"locationRef" yaml:"locationRef"`
    S3BucketName string `json:"s3BucketName" yaml:"s3BucketName"`
}

type AwsVolumeSnapshot

type AwsVolumeSnapshot struct {
    EbsVolumeId string `json:"ebsVolumeId" yaml:"ebsVolumeId" bson:"ebsVolumeId"`
    SnapshotId  string `json:"snapshotId" yaml:"snapshotId" bson:"snapshotId"`
    AccountId   string `json:"accountId" yaml:"accountId" bson:"accountId"`
    // used in cluster restoration process
    OriginalEbsVolumeId string `json:"originalEbsVolumeId" yaml:"originalEbsVolumeId" bson:"originalEbsVolumeId"`
}

type AzureASSecretStoreSpec

AzureASSecretStoreSpec is a spec for secret store in Azure Account Storage.

type AzureASSecretStoreSpec struct {
    // current implementation automatically generate the new!
    // name of container with secrets by next rule concat(deployment().name + 'secrets'.
    // It could be changed in future for some static value secretsContainerName?: string;
    LocationRef string `json:"locationRef" yaml:"locationRef"`
    // UseExisting should use an existing secret store
    UseExisting *bool `json:"useExisting,omitempty" yaml:"useExisting,omitempty"`
    // If omitted, a new Storage Account, otherwise existing will be used
    // +optional
    StorageAccountName string `json:"storageAccountName,omitempty" yaml:"storageAccountName,omitempty"`
    // If omitted, a new  Storage Container under Storage Account will be created, otherwise existing will be used
    // +optional
    StorageContainerName string `json:"storageContainerName,omitempty" yaml:"storageContainerName,omitempty"`
}

type AzureApiAccessKey

AzureApiAccessKey defines Azure credentials.

type AzureApiAccessKey struct {
    TenantId        string `json:"tenantId" yaml:"tenantId"`
    SubscriptionId  string `json:"subscriptionId" yaml:"subscriptionId"`
    AadClientId     string `json:"aadClientId" yaml:"aadClientId"`
    AadClientSecret string `json:"aadClientSecret" yaml:"aadClientSecret"`
}

type AzureDataDiskSpec

AzureDataDiskSpec is a Data disk specification

type AzureDataDiskSpec struct {
    // Lun specifies the logical unit number (LUN) for the data drive in the virtual machine.
    // Each data disk must have a unique LUN.
    Lun int `json:"lun" yaml:"lun"`
    // DiskSizeGB specifies the data disk size, in gigabytes.
    DiskSizeGB int `json:"diskSizeGb" yaml:"diskSizeGb"`
}

type AzureDiskSpec

AzureDiskSpec is a spec for method creation VM in Azure.

type AzureDiskSpec struct {
    Type               *string `json:"type" yaml:"type"`
    ImageID            *string `json:"imageId" yaml:"imageId"`
    ImageResourceGroup *string `json:"imageResourceGroup" yaml:"imageResourceGroup"`
    ImagePublisher     *string `json:"imagePublisher" yaml:"imagePublisher"`
    ImageOffer         *string `json:"imageOffer" yaml:"imageOffer"`
    ImageVersion       *string `json:"imageVersion" yaml:"imageVersion"`
    SourceUri          *string `json:"sourceUri" yaml:"sourceUri"`
}

type AzureInstanceGroupLocationSpec

AzureInstanceGroupLocationSpec is a spec for instance group location in Azure.

type AzureInstanceGroupLocationSpec struct {
    SshKey      *string `json:"sshKey" yaml:"sshKey"`
    SshUsername *string `json:"sshUsername" yaml:"sshUsername"`
    // IsAvailabilitySet indicates usage of Azure availability set
    IsAvailabilitySet bool    `json:"isAvailabilitySet" yaml:"isAvailabilitySet"`
    InstanceType      *string `json:"instanceType" yaml:"instanceType"`
    // OsDisk describes OS disk
    OsDisk AzureDiskSpec `json:"osDisk" yaml:"osDisk"`
    // MasterDataDisk describes master Data disk
    MasterDataDisk *AzureDataDiskSpec `json:"masterDataDisk,omitempty" yaml:"masterDataDisk,omitempty"`
}

type AzureLocationSpec

AzureLocationSpec is a spec for Azure Location.

type AzureLocationSpec struct {
    // AzureApiAccessSecretRef is a reference to the secret object containing Azure secrets to access location
    AzureApiAccessSecretRef *string `json:"azureApiAccessSecretRef" yaml:"azureApiAccessSecretRef"`

    // AzureSshKeySecretRef is a reference to the secret object containing public SSH key
    AzureSshKeySecretRef *string `json:"azureSshKeySecretRef" yaml:"azureSshKeySecretRef"`

    // Azure aadClientId
    AadClientId *string `json:"aadClientId" yaml:"aadClientId"`

    // Region is Azure region
    Region *string `json:"region" yaml:"region"`

    // Azure Resource Group
    // If omitted, a new Resource Group will be created, otherwise existing will be used
    //+optional
    ResourceGroup *string `json:"resourceGroup,omitempty" yaml:"resourceGroup,omitempty"`

    // Azure Network Security Group
    // If omitted, a new Network Security Group will be created, otherwise existing will be used
    //+optional
    NetworkSecurityGroup *string `json:"networkSecurityGroup,omitempty" yaml:"networkSecurityGroup,omitempty"`

    // Azure Route Table
    // If omitted, a new Route Table will be created, otherwise existing will be used
    //+optional
    RouteTable *string `json:"routeTable,omitempty" yaml:"routeTable,omitempty"`

    // Azure Storage Account type (i.e. Standard_LRS, Premium_LRS and etc)
    // If omitted - default will be used.
    StorageAccountType *AzureStorageAccountType `json:"storageAccountType,omitempty" yaml:"storageAccountType,omitempty"`

    // Azure Virtual Network
    // If omitted, a new Virtual Network will be created, otherwise existing will be used
    //+optional
    VirtualNetwork *string `json:"virtualNetwork,omitempty" yaml:"virtualNetwork,omitempty"`

    // Azure Virtual Network Subnet
    // If omitted, a new Virtual Network Subnet will be created, otherwise existing will be used
    //+optional
    VirtualNetworkSubnet *string `json:"virtualNetworkSubnet,omitempty" yaml:"virtualNetworkSubnet,omitempty"`

    // Ip address range for instances in this Virtual Network Subnet
    // If omitted - default will be assigned
    //+optional
    VirtualNetworkSubnetCidrBlock *string `json:"virtualNetworkSubnetCidrBlock,omitempty" yaml:"virtualNetworkSubnetCidrBlock,omitempty"`
}

type AzureLocationState

AzureLocationState represents state of Azure Location.

type AzureLocationState struct {
    ResourceGroupName           string `json:"resourceGroupName" yaml:"resourceGroupName"`
    DeploymentName              string `json:"deploymentName" yaml:"deploymentName"`
    DeploymentProvisioningState string `json:"deploymentProvisioningState" yaml:"deploymentProvisioningState"`
    LastEventDataID             string `json:"lastEventDataId" yaml:"lastEventDataId"`
    FirstStackError             string `json:"firstStackError" yaml:"firstStackError"`
}

type AzureStorageAccountType

AzureStorageAccountType is a Storage Account type (i.e. Standard_LRS, Premium_LRS and etc)

type AzureStorageAccountType string
const (
    // StorageAccountTypeStandard is a Standard storage account tyoe
    StorageAccountTypeStandard AzureStorageAccountType = "Standard_LRS"
    // StorageAccountTypePremium is a Premium (i.e. High-Performance) storage account type
    StorageAccountTypePremium AzureStorageAccountType = "Premium_LRS"
)

type Backup

type Backup struct {
    Entity `json:",inline" yaml:",inline" bson:",inline"`

    // Deprecated: need use OwnerReference
    ClusterId   string      `json:"clusterId" yaml:"clusterId" bson:"clusterId"`
    Spec        BackupSpec  `json:"spec" yaml:"spec" bson:"spec"`
    ClusterSpec ClusterSpec `json:"clusterSpec" yaml:"clusterSpec" bson:"clusterSpec"`
    TotalSize   int64       `json:"totalSize" yaml:"totalSize" bson:"totalSize"`
    FinishedAt  time.Time   `json:"finishedAt" yaml:"finishedAt" bson:"finishedAt"`
}

type BackupConfiguration

type BackupConfiguration struct {
    Entity `json:",inline" yaml:",inline" bson:",inline"`

    ScheduleConfig []ScheduleInterval `json:"scheduleConfig" yaml:"scheduleConfig" bson:"scheduleConfig"`
    Enabled        bool               `json:"enabled" yaml:"enabled" bson:"enabled"`
    DryRun         bool               `json:"dryRun" yaml:"dryRun" bson:"dryRun"`
}

type BackupConfigurationListResult

type BackupConfigurationListResult struct {
    Total int                   `json:"total" yaml:"total" bson:"total"`
    Items []BackupConfiguration `json:"items" yaml:"items" bson:"items"`
}

type BackupListResult

BackupListResult holds Backups.

type BackupListResult struct {
    Total int      `json:"total" yaml:"total" bson:"total"`
    Items []Backup `json:"items" yaml:"items" bson:"items"`
}

type BackupSpec

type BackupSpec struct {
    MasterDisksSnapshots            []VolumeSnapshot `json:"masterDisksSnapshots" yaml:"masterDisksSnapshots" bson:"masterDisksSnapshots"`
    PersistentVolumesSnapshots      []VolumeSnapshot `json:"persistentVolumesSnapshots" yaml:"persistentVolumesSnapshots" bson:"persistentVolumesSnapshots"`
    PersistentVolumeClaimsSnapshots []VolumeSnapshot `json:"persistentVolumeClaimsSnapshots" yaml:"persistentVolumeClaimsSnapshots" bson:"persistentVolumeClaimsSnapshots"`
}

type BackupStats

BackupStats is the backup status of the cluster

type BackupStats struct {
    ClusterID         string    `json:"clusterId" yaml:"clusterId" bson:"clusterId"`
    ClusterName       string    `json:"clusterName" yaml:"clusterName" bson:"clusterName"`
    LastSuccessBackup time.Time `json:"lastSuccessBackup" yaml:"lastSuccessBackup" bson:"lastSuccessBackup"`
    NumberOfBackups   int       `json:"numberOfBackups" yaml:"numberOfBackups" bson:"numberOfBackups"`
}

type BaremetalInstanceGroupLocationSpec

BaremetalInstanceGroupLocationSpec is a spec for instance group location.

type BaremetalInstanceGroupLocationSpec struct {
    // Hosts is a list of hosts in the current instance group location.
    //+optional
    Hosts []HostSpec `json:"hosts,omitempty" yaml:"hosts,omitempty"`
    //load balancing address for apiserver of kubernetes
    //+optional
    LoadBalancerAddress string `json:"loadBalancerAddress,omitempty" yaml:"loadBalancerAddress,omitempty"`
    // Reference to the secret object containing private SSH key for instance group
    // Can be overridden for host in HostSpec
    //+optional
    SshKeySecretRef *string `json:"sshKeySecretRef,omitempty" yaml:"sshKeySecretRef,omitempty"`
    // Username to connect to ssh for instance group
    // Can be overridden for host in HostSpec
    //+optional
    Username string `json:"username,omitempty" yaml:"username,omitempty"`
}

type BaremetalInstanceGroupLocationState

type BaremetalInstanceGroupLocationState struct {
    InstanceGroupRef   string
    HostStates         []HostState
    RegisteredHosts    int
    MinRegisteredHosts int
    DeregisteredHosts  int
    InitCommand        []InitCommand
    RemoveCommand      []RemoveCommand
}

type BaremetalLocationSpec

BaremetalLocationSpec holds location specification for bare metal installations.

type BaremetalLocationSpec struct {
}

type BaremetalLocationState

BaremetalLocationState represents state of Baremetal location.

type BaremetalLocationState struct {
    InstanceGroupStates []BaremetalInstanceGroupLocationState
}

type BaremetalSecretStoreSpec

Spec for bare-metal secret storage. this spec is empty.

type BaremetalSecretStoreSpec struct {
}

type CentralLoggingSinkSpec

SelfHostedClusterLogSinkSpec is a spec for self-hosted cluster wide logging.

type CentralLoggingSinkSpec struct {
    // Enabled indicates if this sink is enabled.
    Enabled bool `json:"enabled" yaml:"enabled"`
    // Persistent indicates if EL storage is persistent.
    Persistent bool `json:"persistent" yaml:"persistent"`
    // Size definesGenerate certificate for jwks size of the storage for elasticsearch in platform, string, must follow k8s resource.Quantity rules.
    Size string `json:"size" yaml:"size"`
    // MasterNodes is the number of master nodes that control the cluster.
    // number of master nodes is must not be 2, need to use 1 or 3 and more
    MasterNodes int `json:"masterNodes" yaml:"masterNodes" bson:"masterNodes"`
    // DataNodes is the number of data nodes that hold data and perform data related operations such as CRUD, search, and aggregations.
    DataNodes int `json:"dataNodes" yaml:"dataNodes" bson:"dataNodes"`
    // ClientNodes is the number of client nodes which serve client requests.
    ClientNodes int `json:"clientNodes" yaml:"clientNodes" bson:"clientNodes"`
}

type Chart

Chart is a helm package

type Chart struct {
    // The name of the chart
    Name string `json:"name,omitempty" yaml:"name,omitempty"`
    // RepoUrl is address of helm repository
    RepoUrl string `json:"repoUrl,omitempty" yaml:"repoUrl,omitempty"`
    // Version of the chart
    Version string `json:"version,omitempty" yaml:"version,omitempty"`
}

type ChartValues

ChartValues represents helm chart values

type ChartValues map[string]interface{}

type Cluster

Cluster is a definition of cluster.

type Cluster struct {
    Entity `json:",inline" yaml:",inline" bson:",inline"`
    // Spec is cluster specification.
    Spec ClusterSpec `valid:"required" json:"spec" yaml:"spec"`
    // Status hold cluster state.
    Status ClusterState `valid:"" json:"status,omitempty" yaml:"status,omitempty"`

    // Owner is an owner for cluster.
    Owner *Owner `json:"owner,omitempty" yaml:"owner,omitempty"`

    // Deleted indicates whether cluster was removed
    Deleted bool `json:"deleted" yaml:"deleted" default:"false"`
}

type ClusterBackupDetails

type ClusterBackupDetails struct {
    Cluster           Cluster   `json:"cluster" yaml:"cluster" bson:"cluster"`
    LastSuccessBackup time.Time `json:"lastSuccessBackup" yaml:"lastSuccessBackup" bson:"lastSuccessBackup"`
    NumberOfBackups   int       `json:"numberOfBackups" yaml:"numberOfBackups" bson:"numberOfBackups"`
    BackupEnabled     bool      `json:"backupEnabled" yaml:"backupEnabled" bson:"backupEnabled"`
}

type ClusterBackupDetailsListResult

type ClusterBackupDetailsListResult struct {
    Total int                    `json:"total" yaml:"total" bson:"total"`
    Items []ClusterBackupDetails `json:"items" yaml:"items" bson:"items"`
}

type ClusterCentralMonitoringSpec

ClusterCentralMonitoringSpec is a spec for centralized monitoring feature Deprecated

type ClusterCentralMonitoringSpec struct {
    // Chart is a helm package
    Chart *Chart `json:"chart,omitempty" yaml:"chart,omitempty"`
    // Enabled indicates if this feature is enabled.
    Enabled bool `json:"enabled" yaml:"enabled"`
    // Local is a spec for local central monitoring installation
    Local *LocalCentralMonitoringSpec `json:"local,omitempty" yaml:"local,omitempty"`
}

type ClusterFeaturesSpec

ClusterFeaturesSpec is a spec for cluster-wide features.

type ClusterFeaturesSpec struct {
    Logging    *ClusterLoggingSpec    `json:"logging,omitempty" yaml:"logging,omitempty"`
    Monitoring *ClusterMonitoringSpec `json:"monitoring,omitempty" yaml:"monitoring,omitempty"`
    // CentralMonitoring is a spec from app-monitoring feature
    // Deprecated: Use Monitoring instead
    CentralMonitoring *ClusterCentralMonitoringSpec `json:"centralMonitoring,omitempty" yaml:"centralMonitoring,omitempty"`
    Ingress           *ClusterIngressSpec           `json:"ingress,omitempty" yaml:"ingress,omitempty"`
    ControlPlane      *ControlPlaneFeatureSpec      `json:"controlPlane,omitempty" yaml:"controlPlane,omitempty"`
    AppFeature        *AppFeatureSpec               `json:"appFeature,omitempty" yaml:"appFeature,omitempty"`
}

type ClusterIngressControllerSpec

ClusterIngressControllerSpec is a spec for cluster-wide ingress controller.

type ClusterIngressControllerSpec struct {
    Nginx *NginxClusterIngressControllerSpec
}

type ClusterIngressSpec

ClusterIngressSpec is a spec for Ingress in cluster.

type ClusterIngressSpec struct {
    // Chart is a helm package
    Chart *Chart `json:"chart,omitempty" yaml:"chart,omitempty"`
    // Values is a helm chart values
    Values *ChartValues `json:"values,omitempty" yaml:"values,omitempty"`

    IngressControllers []*ClusterIngressControllerSpec `json:"ingressControllers,omitempty" yaml:"ingressControllers,omitempty"`
}

type ClusterListResult

ClusterListResult holds clusters.

type ClusterListResult struct {
    Total int       `json:"total" yaml:"total"`
    Items []Cluster `json:"items" yaml:"items"`
}

type ClusterLogCollectionSpec

ClusterLogCollectionSpec is a spec for cluster log collection.

type ClusterLogCollectionSpec struct {
    // Enabled is a flag indicating if log collection is enabled.
    Enabled bool `json:"enabled" yaml:"enabled"`
}

type ClusterLogSinksSpec

ClusterLogSinksSpec is a spec for Cluster wide log sinks.

type ClusterLogSinksSpec struct {
    SelfHosted     *SelfHostedClusterLogSinkSpec `json:"selfHosted,omitempty" yaml:"selfHosted,omitempty"`
    AwsCloudWatch  *AwsCloudWatchLogSinkSpec     `json:"awsCloudWatch,omitempty" yaml:"awsCloudWatch,omitempty"`
    CentralLogging *CentralLoggingSinkSpec       `json:"centralLogging,omitempty" yaml:"centralLogging,omitempty"`
}

type ClusterLoggingSpec

ClusterLoggingSpec is a spec for cluster wide logging.

type ClusterLoggingSpec struct {
    // Chart is a helm package
    Chart *Chart `json:"chart,omitempty" yaml:"chart,omitempty"`
    // Values is a helm chart values
    Values *ChartValues `json:"values,omitempty" yaml:"values,omitempty"`

    LogCollection *ClusterLogCollectionSpec `json:"logCollection" yaml:"logCollection"`
    Sinks         []*ClusterLogSinksSpec    `json:"sinks,omitempty" yaml:"sinks,omitempty"`
}

type ClusterMonitoringSpec

ClusterMonitoringSpec is a spec for cluster wide monitoring.

type ClusterMonitoringSpec struct {
    // Chart is a helm package
    Chart *Chart `json:"chart,omitempty" yaml:"chart,omitempty"`
    // Values is a helm chart values
    Values *ChartValues `json:"values,omitempty" yaml:"values,omitempty"`

    Enabled        bool                          `json:"enabled,omitempty" yaml:"enabled,omitempty"`
    Platform       *MonitoringPlatformSpec       `json:"platform,omitempty" yaml:"platform,omitempty"`
    PlatformClient *MonitoringPlatformClientSpec `json:"platformClient,omitempty" yaml:"platformClient,omitempty"`
    SelfHosted     *MonitoringSelfHostedSpec     `json:"selfHosted,omitempty" yaml:"selfHosted,omitempty"`

    // StatsCollection is a stats collection spec
    // Deprecated kept here just for backward compatibility
    StatsCollection *ClusterStatsCollectionSpec `json:"statsCollection,omitempty" yaml:"statsCollection,omitempty"`
}

type ClusterSpec

ClusterSpec is a specification of the cluster.

type ClusterSpec struct {
    // KublrVersion allows to specify which version of kublr to use.
    KublrVersion *string `valid:"ascii,required" json:"kublrVersion" yaml:"kublrVersion"`
    // KublrBranch allows to specify which branch to use for cluster.
    KublrBranch *string `valid:"ascii,required" json:"kublrBranch" yaml:"kublrBranch"`

    // KublrAgentConfig allows to override Kublr agent configuration
    //+optional
    KublrAgentConfig *AgentConfigMap `json:"kublrAgentConfig,omitempty" yaml:"kublrAgentConfig,omitempty"`

    // KublrAgentTgzURL specifies URL of Kublr agent to use
    // +optional
    KublrAgentTgzURL *string `json:"kublrAgentTgzUrl" yaml:"kublrAgentTgzUrl"`
    // KublrAgentRepositorySecretRef specifies reference to the secret object containing username/password to access Kublr agent repository
    // +optional
    KublrAgentRepositorySecretRef *string `json:"kublrAgentRepositorySecretRef" yaml:"kublrAgentRepositorySecretRef"`
    // KublrAgentRepositoryUsername specifies username to download kublr agent.
    // Deprecated: use KublrAgentRepositorySecretRef instead
    // +optional
    KublrAgentRepositoryUsername *string `json:"kublrAgentRepositoryUsername" yaml:"kublrAgentRepositoryUsername"`
    // KublrAgentRepositoryPassword specifies password to download kublr agent.
    // Deprecated: use KublrAgentRepositorySecretRef instead
    // +optional
    KublrAgentRepositoryPassword *string `json:"kublrAgentRepositoryPassword" yaml:"kublrAgentRepositoryPassword"`
    // DockerRegistry allows to override docker registries used to pull system docker images
    DockerRegistry *DockerRegistrySpec `json:"dockerRegistry" yaml:"dockerRegistry"`
    // Locations specifies locations where cluster should be installed.
    Locations []*LocationSpec `json:"locations,omitempty" yaml:"locations,omitempty"`
    // Network is a specification of network.
    Network *NetworkSpec `json:"network,omitempty" yaml:"network,omitempty"`
    // Master is a spec for instance group used for kubernetes master nodes.
    Master *InstanceGroupSpec `json:"master,omitempty" yaml:"master,omitempty"`
    // Nodes is a slice with specs for instance groups used for worker nodes.
    Nodes []*InstanceGroupSpec `json:"nodes,omitempty" yaml:"nodes,omitempty"`
    // Features is a specification of cluster features.
    Features *ClusterFeaturesSpec `json:"features" yaml:"features"`
    // SecretStore is a spec for secret store.
    SecretStore *SecretStoreSpec `json:"secretStore" yaml:"secretStore"`
}

type ClusterState

ClusterState represents status of the cluster. TODO: Should be renamed to ClusterStatus

type ClusterState struct {
    CreateRequested  time.Time `json:"createRequested" yaml:"createRequested"`
    Created          time.Time `json:"created" yaml:"created"`
    UpdateRequested  time.Time `json:"updateRequested" yaml:"updateRequested"`
    Updated          time.Time `json:"updated" yaml:"updated"`
    DeleteRequested  time.Time `json:"deleteRequested" yaml:"deleteRequested"`
    Deleted          time.Time `json:"deleted" yaml:"deleted"`
    MonitorRequested time.Time `json:"monitorRequested" yaml:"monitorRequested"`
    Monitored        time.Time `json:"monitored" yaml:"monitored"`

    // KubernetesConfigBucket name of the bucket where kubernetes config file is stored.
    KubernetesConfigBucket string `json:"kubernetesConfigBucket" yaml:"kubernetesConfigBucket"`
    // KubernetesConfigOk represents condition of kubernetes config.
    KubernetesConfigOk *Condition `json:"kubernetesConfigOk" yaml:"kubernetesConfigOk"`

    // Cluster's certificates (used for baremetal clusters)
    ClusterCerts *gencert.ClusterCertificates `json:"clusterCerts" yaml:"clusterCerts"`

    // Cluster Authentication Files (basic_auth.csv, known_tokens.csv, abac-authz-policy.jsonl, config)
    AuthFiles *gencert.AuthFiles `json:"authFiles" yaml:"authFiles"`

    // APIEndpoint is API endpoint to access cluster.
    APIEndpoint string `json:"apiEndpoint" yaml:"apiEndpoint"`
    // APIOk represents condition of API.
    APIOk *Condition `json:"apiOk" yaml:"apiOk"`

    MastersOk            *Condition `json:"mastersOk" yaml:"mastersOk"`
    NodesOk              *Condition `json:"nodesOk" yaml:"nodesOk"`
    DNSOk                *Condition `json:"dnsOk" yaml:"dnsOk"`
    TillerOk             *Condition `json:"tillerOk" yaml:"tillerOk"`
    OverallClusterStatus *Condition `json:"overallClusterStatus" yaml:"overallClusterStatus" bson:"overallClusterStatus"`

    // DashboardEndpoint is endpoint to Access Kubernetes Dashboard.
    DashboardEndpoint string     `json:"dashboardEndpoint" yaml:"dashboardEndpoint"`
    DashboardOk       *Condition `json:"dashboardOk" yaml:"dashboardOk"`

    Conditions     []*Condition     `json:"conditions" yaml:"conditions"`
    LocationStates []*LocationState `json:"locationStates" yaml:"locationStates"`

    // FeatureStates represents the common state of the deployed features.
    FeatureStates []*FeatureState `json:"featureStates" yaml:"featureStates"`

    // DetailedFeatureStates represents the detailed state of the deployed features.
    DetailedFeatureStates DetailedFeatureStates `json:"detailedFeatureStates" yaml:"detailedFeatureStates"`

    // State is a current state of the cluster (i.e. Creating, Running, Error, Deleting, Deleted).
    State CurrentState `json:"state" yaml:"state"`
    // IngressLoadBalancer represents state of the ingress load balancer.
    IngressLoadBalancer IngressLoadBalancer `json:"ingressLoadBalancer" yaml:"ingressLoadBalancer" bson:"ingressLoadBalancer"`
}

type ClusterStatsCollectionSpec

ClusterStatsCollectionSpec is a specification for cluster-wide statistic collection. Deprecated kept here just for backward compatibility

type ClusterStatsCollectionSpec struct {
    Enabled bool `json:"enabled" yaml:"enabled"`
}

type Condition

Condition represents custom condition.

type Condition struct {
    Type               ConditionType   `json:"type" yaml:"type"`
    LastCheckTime      time.Time       `json:"lastCheckTime" yaml:"lastCheckTime"`
    LastTransitionTime time.Time       `json:"lastTransitionTime" yaml:"lastTransitionTime"`
    Status             ConditionStatus `json:"status" yaml:"status"`
    Reason             string          `json:"reason" yaml:"reason"`
    Message            string          `json:"message" yaml:"message"`
}

type ConditionStatus

ConditionStatus represent status of the condition.

type ConditionStatus string
const (
    // ConditionStatusTrue is a value when condition is true.
    ConditionStatusTrue ConditionStatus = ConditionStatus("True")
    // ConditionStatusFalse is a value when condition is false.
    ConditionStatusFalse ConditionStatus = ConditionStatus("False")
    // ConditionStatusUnknown is a value when condition state is unknown.
    ConditionStatusUnknown ConditionStatus = ConditionStatus("Unknown")
)

type ConditionType

ConditionType represents type of the condition.

type ConditionType string
const (
    // LocationOk is a condition type for location.
    LocationOk ConditionType = ConditionType("LocationOk")
    // KubernetesConfigOk is condition type for kubernetes config.
    KubernetesConfigOk ConditionType = ConditionType("KubernetesConfigOk")
    // ApiOk is condition type for API Server status.
    ApiOk ConditionType = ConditionType("ApiOk")
    // MastersOk is a condition type for master node group.
    MastersOk ConditionType = ConditionType("MastersOk")
    // NodesOk is a condition type for worker node groups.
    NodesOk ConditionType = ConditionType("NodesOk")
    // DnsOk is a condition type for kube-dns.
    DnsOk ConditionType = ConditionType("DnsOk")
    // TillerOk is a condition type for helm tiller.
    TillerOk ConditionType = ConditionType("TillerOk")
    // DashboardOk is a condition type for kubernetes dashboard.
    DashboardOk ConditionType = ConditionType("DashboardOk")
    // FeatureOk is a condition type for cluster feature.
    FeatureOk ConditionType = ConditionType("FeatureOk")
    // RegisterHostOk is a condition type for cluster node.
    RegisterHostOk ConditionType = ConditionType("RegisterHostOk")
    // DeregisterHost is a condition type for cluster node.
    DeregisterHostOk ConditionType = ConditionType("DeregisterHostOk")
    // IngressLoadBalancerOk is a condition type for ingress load balancer.
    IngressLoadBalancerOk ConditionType = ConditionType("IngressLoadBalancerOk")
)

type ControlPlaneFeatureSpec

ControlPlaneFeatureSpec is a spec for control plane (kublr) feature in cluster.

type ControlPlaneFeatureSpec struct {
    // Chart is a helm package
    Chart *Chart `json:"chart,omitempty" yaml:"chart,omitempty"`
    // Values is a helm chart values
    Values *ChartValues `json:"values,omitempty" yaml:"values,omitempty"`

    // Namespace kubernetes namespace to which control plane will be installed.
    Namespace *string `json:"namespace,omitempty" yaml:"namespace,omitempty"`
    // Domain is a DNS name which will be used for API/UI/Auth.
    Domain string `json:"domain" yaml:"domain"`
    // InitialAdminPassword password of admin user used for accessing kublr.
    InitialAdminPassword string `json:"initialAdminPassword" yaml:"initialAdminPassword"`
}

type ControlPlaneState

ControlPlaneState represents state of the Control Plane feature.

type ControlPlaneState struct {
    ApiEndpoint       string    `json:"apiEndpoint" yaml:"apiEndpoint" bson:"apiEndpoint"`
    AuthEndpoint      string    `json:"authEndpoint" yaml:"authEndpoint" bson:"authEndpoint"`
    AuthTokenEndpoint string    `json:"authTokenEndpoint" yaml:"authTokenEndpoint" bson:"authTokenEndpoint"`
    UIEndpoint        string    `json:"uiEndpoint" yaml:"uiEndpoint" bson:"uiEndpoint"`
    ReadyState        Condition `json:"readyState" yaml:"readyState" bson:"readyState"`
}

type CurrentState

CurrentState represents current state of the cluster.

type CurrentState string
const (
    // CurrentStateDraft - cluster is in draft state
    CurrentStateDraft CurrentState = "Draft"
    // CurrentStateCreating - cluster is creating.
    CurrentStateCreating CurrentState = "Creating"
    // CurrentStateUpdating - cluster is updating.
    CurrentStateUpdating CurrentState = "Updating"
    // CurrentStateDeleting - cluster is deleting.
    CurrentStateDeleting CurrentState = "Deleting"
    // CurrentStateRunning - cluster is running.
    CurrentStateRunning CurrentState = "Running"
    // CurrentStateDeleted - cluster is deleted.
    CurrentStateDeleted CurrentState = "Deleted"
    // CurrentStateError - cluster in error state.
    CurrentStateError CurrentState = "Error"
)

type DetailedFeatureStates

DetailedFeatureStates represents the detailed state of the deployed features.

type DetailedFeatureStates struct {
    ControlPlaneState *ControlPlaneState      `json:"controlPlaneState,omitempty" yaml:"controlPlaneState,omitempty" bson:"controlPlaneState,omitempty"`
    LoggingState      *LoggingFeatureState    `json:"loggingState,omitempty" yaml:"loggingState,omitempty" bson:"loggingState,omitempty"`
    MonitoringState   *MonitoringFeatureState `json:"monitoringState,omitempty" yaml:"monitoringState,omitempty" bson:"monitoringState,omitempty"`
}

type DockerRegistryAuth

DockerRegistryAuth is a docker registry authentication information

type DockerRegistryAuth struct {
    Registry  *string `json:"registry,omitempty" yaml:"registry,omitempty"`
    SecretRef *string `json:"secretRef,omitempty" yaml:"secretRef,omitempty"`
}

type DockerRegistryOverride

DockerRegistryOverride is a docker registry overrides

type DockerRegistryOverride struct {
    Default   string `json:"default,omitempty" yaml:"default,omitempty"`
    DockerIO  string `json:"docker_io,omitempty" yaml:"docker_io,omitempty"`
    GcrIO     string `json:"gcr_io,omitempty" yaml:"gcr_io,omitempty"`
    K8sGcrIO  string `json:"k8s_gcr_io,omitempty" yaml:"k8s_gcr_io,omitempty"`
    QuayIO    string `json:"quay_io,omitempty" yaml:"quay_io,omitempty"`
    ElasticCO string `json:"elastic_co,omitempty" yaml:"elastic_co,omitempty"`
}

type DockerRegistrySpec

DockerRegistrySpec is a spec for docker registry

type DockerRegistrySpec struct {
    Auth     []*DockerRegistryAuth   `json:"auth,omitempty" yaml:"auth,omitempty"`
    Override *DockerRegistryOverride `json:"override,omitempty" yaml:"override,omitempty"`
}

type ElastigroupSpec

ElastigroupSpec object describes elastigroup parameters for a specific node group

type ElastigroupSpec struct {
    SpotinstAccessTokenSecretRef *string `json:"spotinstAccessTokenSecretRef" bson:"spotinstAccessTokenSecretRef" yaml:"spotinstAccessTokenSecretRef"`

    // Spec - Content of this object should correspond with 'Properties' object structure
    // of CloudFormation custom resoure of type 'Custom::elasticgroup' as described in
    // spotinst documentation, e.g.
    // https://api.spotinst.com/provisioning-ci-cd-sdk/provisioning-tools/cloudformation/examples/elastigroup/create-generic/
    //
    // In particular it may include 'group', 'updatePolicy', 'deletePolicy' properties etc.
    //
    // Kublr generator will override or extend certain elsatigroup spec properties
    // according to generic parameters in the instance group specification, e.g.
    // min/max nodes, instance type, etc
    Spec *ElastigroupSpecMap `json:"spec" yaml:"spec" bson:"spec"`
}

type ElastigroupSpecMap

ElastigroupSpecMap is a spec for elastigroup.

type ElastigroupSpecMap map[string]interface{}

type Entity

type Entity struct {
    // ID is object id assigned by MongoDB during save.
    ID string `json:"id" yaml:"id" bson:"_id,omitempty"`
    // Metadata is object metadata.
    Metadata ObjectMeta `valid:"" json:"metadata" yaml:"metadata" bson:"metadata"`
    // TypeMeta is type metadata.
    TypeMeta `valid:"-" json:",inline" yaml:",inline"`
}

type Event

Event is a definition of events, which happens with cluster.

type Event struct {
    Entity `json:",inline" yaml:",inline" bson:",inline"`

    // InvolvedObject is the object that this event is about.
    // Intended usage is to put reference to kubernetes object to which this event about.
    InvolvedObject *ObjectReference `json:"involvedObject,omitempty" yaml:"involvedObject,omitempty"`
    Reason         string           `json:"reason" yaml:"reason"`
    Message        string           `json:"message" yaml:"message"`
    Source         *EventSource     `json:"eventSource,omitempty" yaml:"eventSource,omitempty"`
    FirstTimestamp time.Time        `json:"firstTimestamp" yaml:"firstTimestamp"`
    LastTimestamp  time.Time        `json:"lastTimestamp" yaml:"lastTimestamp"`
    Count          int              `json:"count" yaml:"count"`
    // Severity is an Event Severity.
    Severity EventSeverity `json:"severity" yaml:"severity"`
    // ClusterID is an ID of the cluster to which this event belongs.
    ClusterID string `json:"clusterId" yaml:"clusterId" bson:"clusterId"`
}

type EventListResult

EventListResult holds Events.

type EventListResult struct {
    Total int     `json:"total" yaml:"total"`
    Items []Event `json:"items" yaml:"items"`
}

type EventSeverity

EventSeverity is a severity of the event.

type EventSeverity int
const (
    // EventSeverityNormal defines normal severity.
    EventSeverityNormal EventSeverity = 1 << iota
    // EventSeverityWarning defines warning severity.
    EventSeverityWarning
    // EventSeverityError defines Error severity.
    EventSeverityError
)

type EventSource

EventSource defines source of the event.

type EventSource struct {
    // Component - which component created the event.
    Component string `json:"component" yaml:"component"`
    // Host is a host on which event was initiated.
    Host string `json:"host" yaml:"host"`
}

type FeatureName

FeatureName is the type for the feature name

type FeatureName string
const (
    FeatureNameKublrApplications FeatureName = "kublr-applications"
    FeatureNameControlPlane      FeatureName = "control-plane"
    FeatureNameIngress           FeatureName = "kublr-feature-ingress"
    FeatureNameKublrSystem       FeatureName = "kublr-system"
    FeatureNameLogging           FeatureName = "kublr-logging"
    FeatureNameMonitoring        FeatureName = "kublr-monitoring"
)

type FeatureState

FeatureState represents state of the deployed feature.

type FeatureState struct {
    FeatureName FeatureName `json:"featureName" yaml:"featureName"`
    ReleaseName string      `json:"releaseName" yaml:"releaseName"`
    Created     time.Time   `json:"created" yaml:"created"`
    Modified    time.Time   `json:"modified" yaml:"modified"`
    Deleted     time.Time   `json:"deleted" yaml:"deleted"`
    FeatureOk   *Condition  `json:"featureOk" yaml:"featureOk"`
    // Namespace is kubernetes namespace to which the feature is installed.
    Namespace string `json:"namespace" yaml:"namespace"`
    // Version is the version of the installed feature
    Version string `json:"version" yaml:"version"`
    // Sha256sum is the SHA256 checksum for the installed function
    Sha256sum string `json:"sha256sum" yaml:"sha256sum"`
}

type GCPAPIAccessKeySpec

type GCPAPIAccessKeySpec struct {
    ClientEmail string `json:"clientEmail,omitempty" yaml:"clientEmail,omitempty"`
    PrivateKey  string `json:"privateKey,omitempty" yaml:"privateKey,omitempty"`
    ProjectID   string `json:"projectId,omitempty" yaml:"projectId,omitempty"`
}

type GCPDiskSpec

type GCPDiskSpec struct {
    SizeGb      *int             `json:"sizeGb,omitempty" yaml:"sizeGb,omitempty"`
    Type        *GCPDiskTypeEnum `json:"type,omitempty" yaml:"type,omitempty"`
    SourceImage *string          `json:"sourceImage,omitempty" yaml:"sourceImage,omitempty"`
}

type GCPDiskTypeEnum

type GCPDiskTypeEnum string
const (
    GCPDiskTypeStandart GCPDiskTypeEnum = "pd-standard"
    GCPDiskTypeSSD      GCPDiskTypeEnum = "pd-ssd"
)

type GCPInstanceGroupLocationSpec

type GCPInstanceGroupLocationSpec struct {
    InstanceType   *string      `json:"instanceType,omitempty" yaml:"instanceType,omitempty"`
    SSHKey         *string      `json:"sshKey,omitempty" yaml:"sshKey,omitempty"`
    BootDisk       *GCPDiskSpec `json:"bootDisk,omitempty" yaml:"bootDisk,omitempty"`
    MasterDataDisk *GCPDiskSpec `json:"masterDataDisk,omitempty" yaml:"masterDataDisk,omitempty"`
    // Zones to limit this group to.
    // If omitted, generator will automatically assign it to all available zones.
    Zones []*string `json:"zones,omitempty" yaml:"zones,omitempty"`
}

type GCPLocationSpec

type GCPLocationSpec struct {
    // Reference to the secret object containing Google Cloud secrets to access
    GCPApiAccessSecretRef *string `json:"gcpApiAccessSecretRef,omitempty" yaml:"gcpApiAccessSecretRef,omitempty"`
    // Reference to the secret object containing public SSH key
    SshKeySecretRef *string `json:"sshKeySecretRef,omitempty" yaml:"sshKeySecretRef,omitempty"`
    // Google Cloud Project ID
    // If omitted, it will be populated automatically based on the secret.
    ProjectID *string `json:"projectId,omitempty" yaml:"projectId,omitempty"`
    // Google Cloud region
    // refer to https://cloud.google.com/compute/docs/regions-zones/
    Region *string `json:"region,omitempty" yaml:"region,omitempty"`
    // Google Cloud region zones to be used for Kubernetes cluster in this location.
    // If omitted, it will be populated automatically to all zones available for this project in this region.
    Zones []*string `json:"zones,omitempty" yaml:"zones,omitempty"`
    // Ip address range for instances in VPC network
    // If omitted - default will be assigned.
    VPCCidrBlock *string `json:"vpcCidrBlock,omitempty" yaml:"vpcCidrBlock,omitempty"`
}

type GCPLocationState

GCPLocationState represents state of GCP Location.

type GCPLocationState struct {
    DeploymentName            string   `json:"deploymentName" yaml:"deploymentName"`
    DeploymentState           string   `json:"deploymentState" yaml:"deploymentState"`
    PrepareToCreateDeployment bool     `json:"prepareToCreateDeployment" yaml:"prepareToCreateDeployment"`
    InstanceGroups            []string `json:"instanceGroups" yaml:"instanceGroups"`
}

type GlobalRole

GlobalRole is in global scope, not in any space

type GlobalRole struct {
    Entity `json:",inline" yaml:",inline" bson:",inline"`
    // Rules holds all the PolicyRules for this Role
    Rules []PolicyRule `json:"rules" yaml:"rules"`
}

type GlobalRoleBinding

GlobalRoleBinding is in the global scope

type GlobalRoleBinding struct {
    Entity `json:",inline" yaml:",inline" bson:",inline"`
    // RoleRef can only reference a GlobalRole in the global space.
    // If the RoleRef cannot be resolved, the Authorizer must return an error.
    RoleRef RoleRef `json:"roleRef" yaml:"roleRef"`
    // Subjects holds references to the objects the role applies to.
    Subjects []Subject `json:"subjects" yaml:"subjects"`
}

type GlobalRoleBindingListResult

GlobalRoleBindingListResult is a collection of GlobalRoleBindings

type GlobalRoleBindingListResult struct {
    Total int `json:"total" yaml:"total"`
    // Items is a list of roleBindings
    Items []GlobalRoleBinding `json:"items" yaml:"items"`
}

type GlobalRoleListResult

GlobalRoleListResult is a collection of GlobalRoles

type GlobalRoleListResult struct {
    Total int `json:"total" yaml:"total"`
    // Items is a list of roles
    Items []GlobalRole `json:"items" yaml:"items"`
}

type GoogleGCSSecretStoreSpec

type GoogleGCSSecretStoreSpec struct {
    LocationRef string `json:"locationRef,omitempty" yaml:"locationRef,omitempty"`
    BucketName  string `json:"bucketName,omitempty" yaml:"bucketName,omitempty"`
}

type GrafanaLocalCentralMonitoringSpec

GrafanaLocalCentralMonitoringSpec is a spec for Grafana installation Deprecated kept here just for backward compatibility

type GrafanaLocalCentralMonitoringSpec struct {
    // Enabled indicates if Grafana is enabled.
    Enabled bool `json:"enabled" yaml:"enabled"`
    // Persistent indicates if storage is enabled.
    Persistent bool `json:"persistent" yaml:"persistent"`
    // Size defines size of the storage, string, must follow k8s resource.Quantity rules.
    Size string `json:"size" yaml:"size"`
}

type GrafanaSpec

GrafanaLocalSpec is a spec for Grafana installation

type GrafanaSpec struct {
    // Enabled indicates if Grafana is enabled.
    Enabled bool `json:"enabled" yaml:"enabled"`
    // Persistent indicates if storage is enabled.
    Persistent bool `json:"persistent" yaml:"persistent"`
    // Size defines size of the storage, string, must follow k8s resource.Quantity rules.
    Size string `json:"size" yaml:"size"`
}

type HostSpec

HostSpec is a spec for a host in bare-metal installations.

type HostSpec struct {
    // Address is a reachable address for the host. Can be hostname or an IP-address.
    Address *string `json:"address,omitempty" yaml:"address,omitempty"`
    // Reference to the secret object containing private SSH key
    SshKeySecretRef *string `json:"sshKeySecretRef,omitempty" yaml:"sshKeySecretRef,omitempty"`
    // Username to connect to ssh
    Username string `json:"username,omitempty" yaml:"username,omitempty"`
}

type HostState

HostState represents state of the host.

type HostState struct {
    Address      string
    RegisterOk   Condition
    DeregisterOk Condition
}

type IdentifiableEntity

type IdentifiableEntity interface {
    GetID() string
    SetID(string)
    GetMetadata() ObjectMeta
    GetTypeMeta() TypeMeta
    SetResourceVersion(version int)
    SetSpace(space string)
    SetLabels(labels map[string]string)
    GetResourceVersion() int
    GetCreatedTimestamp() time.Time
    GetUpdatedTimestamp() time.Time
    SetCreatedTimestamp(t time.Time)
    SetUpdatedTimestamp(t time.Time)
}

type IngressLoadBalancer

IngressLoadBalancer represents state of the ingress load balancer.

type IngressLoadBalancer struct {
    // Address represents DNS name or IP address of load balancer.
    // for Amazon - DNS name
    // for Azure - IP address
    Address string `json:"address" yaml:"address" bson:"address"`
    // LoadBalancerOk represents condition of load balancer.
    LoadBalancerOk *Condition `json:"loadBalancerOk" yaml:"loadBalancerOk" bson:"loadBalancerOk"`
    // HttpPort represents the port for the http connection.
    HttpPort int32
    // HttpsPort represents the port for the https connection.
    HttpsPort int32
}

type InitCommand

InitCommand specifies command to be used for initialization of new node in the location state.

type InitCommand struct {
    // NodeGroup name of the group to which command applies.
    NodeGroup string `json:"nodeGroup" yaml:"nodeGroup"`
    // NodeOrdinal is an ordinal within group.
    NodeOrdinal int64 `json:"nodeOrdinal" yaml:"nodeOrdinal"`
    // Command is a command to be executed to init a node.
    Command string `json:"command" yaml:"command"`
}

type InstanceGroupLocationSpec

InstanceGroupLocationSpec is a spec for an instance group location.

type InstanceGroupLocationSpec struct {
    LocationRef *string `json:"locationRef" yaml:"locationRef"`
    // Aws is a spec for AWS installations.
    //+optional
    Aws *AwsInstanceGroupLocationSpec `json:"aws,omitempty" yaml:"aws,omitempty"`
    // Azure is a spec for Azure installations.
    //+optional
    Azure *AzureInstanceGroupLocationSpec `json:"azure,omitempty" yaml:"azure,omitempty"`
    // Baremetal is a spec for bare-metal installation.
    //+optional
    Baremetal *BaremetalInstanceGroupLocationSpec `json:"baremetal,omitempty" yaml:"baremetal,omitempty"`
    // Gcp is a spec to Google Cloud installations.
    //+optional
    Gcp *GCPInstanceGroupLocationSpec `json:"gcp,omitempty" yaml:"gcp,omitempty"`

    // KublrAgentConfig allows to override Kublr agent configuration
    //+optional
    KublrAgentConfig *AgentConfigMap `json:"kublrAgentConfig,omitempty" yaml:"kublrAgentConfig,omitempty"`
}

type InstanceGroupSpec

InstanceGroupSpec is a spec for instance group.

type InstanceGroupSpec struct {
    Name *string `valid:"alphanum,required" json:"name" yaml:"name"`
    // KublrVariant is a variant to use for this group.
    // If omitted, generator will try to assign it automatically.
    //+optional
    KublrVariant *string `valid:"ascii,required" json:"kublrVariant" yaml:"kublrVariant"`
    MinNodes     *int    `json:"minNodes,omitempty" yaml:"minNodes,omitempty"`
    InitialNodes *int    `json:"initialNodes,omitempty" yaml:"initialNodes,omitempty"`
    MaxNodes     *int    `json:"maxNodes,omitempty" yaml:"maxNodes,omitempty"`
    // Stateful indicates that this group is stateful. It means that Autoscaling MUST be disabled for this group.
    // Also, all nodes will have stable identifiers in the group. (I.e. it will be a pet group, not cattle).
    Stateful bool `json:"stateful" yaml:"stateful"`
    // Autoscaling is a flag indicating if autoscaling is enabled for this group or not.
    Autoscaling bool `json:"autoscaling" yaml:"autoscaling"`
    // Locations is a spec for locations for this group.
    // Only one location per group is currently supported.
    // If omitted, generator will try to assign it automatically to the first available location.
    // +optional
    Locations []*InstanceGroupLocationSpec `json:"locations,omitempty" yaml:"locations,omitempty"`

    // KublrAgentConfig allows to override Kublr agent configuration
    //+optional
    KublrAgentConfig *AgentConfigMap `json:"kublrAgentConfig,omitempty" yaml:"kublrAgentConfig,omitempty"`
}

type ListResult

ListResult holds result of requests returning slice of objects. This is a generic result which can be used only if result should not be processed in any other way.

type ListResult struct {
    Total int           `json:"total" yaml:"total"`
    Items []interface{} `json:"items" yaml:"items"`
}

type LocalCentralMonitoringSpec

LocalCentralMonitoringSpec is a spec for local central monitoring installation Deprecated kept here just for backward compatibility

type LocalCentralMonitoringSpec struct {
    // AlertManager is a spec for AlertManager installation
    AlertManager *AlertManagerLocalCentralMonitoringSpec `json:"alertmanager,omitempty" yaml:"alertmanager,omitempty"`
    // Prometheus is a spec for Prometheus installation
    Prometheus *PrometheusLocalCentralMonitoringSpec `json:"prometheus,omitempty" yaml:"prometheus,omitempty"`
    // Grafana is a spec for Grafana installation
    Grafana *GrafanaLocalCentralMonitoringSpec `json:"grafana,omitempty" yaml:"grafana,omitempty"`
}

type LocationSpec

LocationSpec is a spec for a location. Only one spec should be not-nil inside.

type LocationSpec struct {
    // Name is a name of the location.
    Name *string `json:"name" yaml:"name"`
    // Aws specifies AWS specific details.
    // +optional
    Aws *AwsLocationSpec `json:"aws,omitempty" yaml:"aws,omitempty"`
    // Azure specifies Azure specific details.
    // +optional
    Azure *AzureLocationSpec `json:"azure,omitempty" yaml:"azure,omitempty"`
    // Baremetal specifies bare-metal specific details.
    // +optional
    Baremetal *BaremetalLocationSpec `json:"baremetal,omitempty" yaml:"baremetal,omitempty"`
    // Gcp specifies Google Cloud specific details
    // +optional
    Gcp *GCPLocationSpec `json:"gcp,omitempty" yaml:"gcp,omitempty"`

    // KublrAgentConfig allows to override Kublr agent configuration
    //+optional
    KublrAgentConfig *AgentConfigMap `json:"kublrAgentConfig,omitempty" yaml:"kublrAgentConfig,omitempty"`
}

type LocationState

LocationState represents state of the location.

type LocationState struct {
    LocationRef *string `json:"locationRef" yaml:"locationRef"`
    // Aws stores location state for AWS installations.
    //+optional
    Aws *AWSLocationState `json:"aws" yaml:"aws"`
    // Baremetal stores location state for baremetal installations.
    //+optional
    // Azure stores location state for Azure installations.
    //+optional
    Azure *AzureLocationState `json:"azure" yaml:"azure"`
    // Baremetal stores location state for on-prem installations.
    //+optional
    Baremetal *BaremetalLocationState `json:"baremetal" yaml:"baremetal"`
    // Gcp stores location state for GCP installations.
    //+optional
    Gcp *GCPLocationState `json:"gcp" yaml:"gcp"`

    LocationOk      *Condition   `json:"locationOk" yaml:"locationOk"`
    Conditions      []*Condition `json:"conditions" yaml:"conditions"`
    CreateRequested time.Time    `json:"createRequested" yaml:"createRequested"`
    Created         time.Time    `json:"created" yaml:"created"`
    UpdateRequested time.Time    `json:"updateRequested" yaml:"updateRequested"`
    Updated         time.Time    `json:"updated" yaml:"updated"`
    DeleteRequested time.Time    `json:"deleteRequested" yaml:"deleteRequested"`
    Deleted         time.Time    `json:"deleted" yaml:"deleted"`
}

type LoggingFeatureState

LoggingFeatureState represents state of the logging feature.

type LoggingFeatureState struct {
    // KibanaEndpoint represents the endpoint address for kibana service.
    KibanaEndpoint string `json:"kibanaEndpoint" yaml:"kibanaEndpoint" bson:"kibanaEndpoint"`
    // RabbitmqEndpoint represents the endpoint address for rabbitmq service.
    RabbitmqEndpoint string `json:"rabbitmqEndpoint" yaml:"rabbitmqEndpoint" bson:"rabbitmqEndpoint"`
    // Condition represents status of the logging feature.
    Condition Condition `json:"condition" yaml:"condition" bson:"condition"`
}

type MasterELBAllocationPolicyEnum

type MasterELBAllocationPolicyEnum string

type MonitoringFeatureState

MonitoringFeatureState represents state of the app-monitoring feature.

type MonitoringFeatureState struct {
    // Condition represents status of the app-monitoring feature.
    Condition Condition `json:"condition" yaml:"condition" bson:"condition"`

    // AlertManagerEndpoint represents the endpoint address for AlertManager service.
    AlertManagerEndpoint string `json:"alertManagerEndpoint" yaml:"alertManagerEndpoint" bson:"alertManagerEndpoint"`
    // AlertManagerServiceName represents AlertManager service name.
    AlertManagerServiceName string `json:"alertManagerServiceName" yaml:"alertManagerServiceName" bson:"alertManagerServiceName"`

    // GrafanaEndpoint represents the endpoint address for grafana service.
    GrafanaEndpoint string `json:"grafanaEndpoint" yaml:"grafanaEndpoint" bson:"grafanaEndpoint"`
    // GrafanaServiceName represents Grafana service name.
    GrafanaServiceName string `json:"grafanaServiceName" yaml:"grafanaServiceName" bson:"grafanaServiceName"`

    // PrometheusEndpoint represents the endpoint address for Prometheus service.
    PrometheusEndpoint string `json:"prometheusEndpoint" yaml:"prometheusEndpoint" bson:"prometheusEndpoint"`
    // PrometheusServiceName represents Prometheus service name.
    PrometheusServiceName string `json:"prometheusServiceName" yaml:"prometheusServiceName" bson:"prometheusServiceName"`
}

type MonitoringPlatformClientSpec

MonitoringPlatformClientSpec is a specification for Centralized Monitoring Client installation (installs on KCP managed clusters)

type MonitoringPlatformClientSpec struct {
    Enabled bool `json:"enabled" yaml:"enabled"`

    Prometheus PrometheusSpec `json:"prometheus,omitempty" yaml:"prometheus,omitempty"`
}

type MonitoringPlatformSpec

MonitoringPlatformSpec is a specification for Centralized Monitoring Host installation (installs on KCP cluster)

type MonitoringPlatformSpec struct {
    Enabled bool `json:"enabled" yaml:"enabled"`

    // AlertManager is a spec for AlertManager installation
    AlertManager AlertManagerSpec `json:"alertmanager,omitempty" yaml:"alertmanager,omitempty"`
    // Prometheus is a spec for Prometheus installation
    Prometheus PrometheusSpec `json:"prometheus,omitempty" yaml:"prometheus,omitempty"`
    // Grafana is a spec for Grafana installation
    Grafana GrafanaSpec `json:"grafana,omitempty" yaml:"grafana,omitempty"`
}

type MonitoringSelfHostedSpec

MonitoringSelfHostedSpec is a specification for Self-Hosted Monitoring installation

type MonitoringSelfHostedSpec struct {
    Enabled bool `json:"enabled" yaml:"enabled"`

    // AlertManager is a spec for AlertManager installation
    AlertManager AlertManagerSpec `json:"alertmanager,omitempty" yaml:"alertmanager,omitempty"`
    // Prometheus is a spec for Prometheus installation
    Prometheus PrometheusSpec `json:"prometheus,omitempty" yaml:"prometheus,omitempty"`
    // Grafana is a spec for Grafana installation
    Grafana GrafanaSpec `json:"grafana,omitempty" yaml:"grafana,omitempty"`
}

type NetworkSpec

NetworkSpec is a spec of network.

type NetworkSpec struct {
    Provider    *string `json:"provider,omitempty" yaml:"provider,omitempty"`
    ClusterCIDR *string `json:"clusterCIDR,omitempty" yaml:"clusterCIDR,omitempty"`
    ServiceCIDR *string `json:"serviceCIDR,omitempty" yaml:"serviceCIDR,omitempty"`
    PodCIDR     *string `json:"podCIDR,omitempty" yaml:"podCIDR,omitempty"`
    MasterIP    *string `json:"masterIP,omitempty" yaml:"masterIP,omitempty"`
    DNSIp       *string `json:"dnsIP,omitempty" yaml:"dnsIP,omitempty"`
    DNSDomain   *string `json:"dnsDomain,omitempty" yaml:"dnsDomain,omitempty"`
}

type NginxClusterIngressControllerSpec

NginxClusterIngressControllerSpec is a spec for NGINX Ingress Controller.

type NginxClusterIngressControllerSpec struct {
    Acme    *AcmeSpec
    Enabled bool
}

type NodeIPAllocationPolicyEnum

type NodeIPAllocationPolicyEnum string

type ObjectMeta

type ObjectMeta struct {
    Name             string    `valid:"alphanum,required" json:"name" yaml:"name"`
    CreatedTimestamp time.Time `json:"createdAt,omitempty" yaml:"createdAt,omitempty"`
    UpdatedTimestamp time.Time `json:"updatedAt,omitempty" yaml:"updatedAt,omitempty"`

    // Map of string keys and values that can be used to organize and categorize (scope and select) objects.
    // +optional
    Labels map[string]string `json:"labels,omitempty" yaml:"labels,omitempty"`

    // Space defines the name of the space
    // Not all objects are required to be scoped to a space - the value of this field for
    // those objects will be empty.
    Space string `json:"space,omitempty" yaml:"space,omitempty" bson:"space,omitempty"`

    // An opaque value that represents the internal version of this object that can
    // be used by clients to determine when objects have changed. May be used for optimistic
    // concurrency, change detection, and the watch operation on a resource or set of resources.
    // Clients must treat these values as opaque and passed unmodified back to the server.
    ResourceVersion int `json:"resourceVersion,omitempty" yaml:"resourceVersion,omitempty" bson:"resourceVersion,omitempty"`

    // List of objects depended by this object.
    // +optional
    OwnerReferences []OwnerReference `json:"ownerReferences,omitempty" yaml:"ownerReferences,omitempty" bson:"ownerReferences,omitempty"`
}

type ObjectReference

ObjectReference is a reference to the associated object.

type ObjectReference struct {
    TypeMeta  `json:",inline" yaml:",inline"`
    Namespace string `json:"namespace" yaml:"namespace"`
    Name      string `json:"name" yaml:"name"`
    Uid       string `json:"uid" yaml:"uid"`
}

type Owner

Owner represents owner of the entity.

type Owner struct {
    // UserID holds ID of the owner.
    UserID string `json:"userId" bson:"userId,omitempty" yaml:"userId"`
}

type OwnerReference

OwnerReference contains enough information to let you identify an owning object. Currently, an owning object must be in the same space, so there is no space field.

type OwnerReference struct {
    // API version of the referent.
    APIVersion string `json:"apiVersion,omitempty" yaml:"apiVersion,omitempty" bson:"apiVersion,omitempty"`
    // Kind of the referent.
    Kind string `json:"kind" yaml:"kind" bson:"kind"`
    // Name of the referent.
    Name string `json:"name" yaml:"name" bson:"name"`
    // ID of the referent.
    ID string `json:"id" yaml:"id" bson:"id"`
}

type OwnerReferenceFilter

OwnerReferenceFilter describes filter for OwnerReference

type OwnerReferenceFilter func(OwnerReference) bool

type OwnerableEntity

type OwnerableEntity interface {
    IdentifiableEntity
    GetOwner() *Owner
    SetOwner(owner *Owner)
}

type PolicyRule

PolicyRule holds information that describes a policy rule, but does not contain information about who the rule applies to or which space the rule applies to.

type PolicyRule struct {

    // Resources is a list of resources this rule applies to. '*' represents all resources.
    Resources []string `json:"resources" yaml:"resources"`

    // Action constraints
    // 1. allowed actions - e.g. "get", "list", "put", "post", "delete"
    // 2. "*" means all actions allowed
    Verbs []string `json:"verbs" yaml:"verbs"`
}

type PrometheusLocalCentralMonitoringSpec

PrometheusLocalCentralMonitoringSpec is a spec for Prometheus installation Deprecated kept here just for backward compatibility

type PrometheusLocalCentralMonitoringSpec struct {
    // Persistent indicates if storage is enabled.
    Persistent bool `json:"persistent" yaml:"persistent"`
    // Size defines size of the storage, string, must follow k8s resource.Quantity rules.
    Size string `json:"size" yaml:"size"`
}

type PrometheusSpec

PrometheusSpec is a spec for Prometheus installation

type PrometheusSpec struct {
    // Persistent indicates if storage is enabled.
    Persistent bool `json:"persistent" yaml:"persistent"`
    // Size defines size of the storage, string, must follow k8s resource.Quantity rules.
    Size string `json:"size" yaml:"size"`
}

type RegisterNode

Entity to register or unregister from the cluster. Can be used for node or master hosts.

type RegisterNode struct {
    //name from the location specification
    LocationRef string `json:"locationRef" yaml:"locationRef"`
    //name from the instance group specification
    InstanceGroupRef string `json:"instanceGroupRef" yaml:"instanceGroupRef"`
    // host IP address
    Address string `json:"address" yaml:"address"`
}

type RemoveCommand

RemoveCommand specifies the command to remove an existing node from the location state.

type RemoveCommand struct {
    // NodeOrdinal is an ordinal within group.
    NodeOrdinal int64 `json:"nodeOrdinal" yaml:"nodeOrdinal"`
    // Command is a command to be executed to init a node.
    Command string `json:"command" yaml:"command"`
}

type Role

type Role string

type RoleRef

RoleRef contains information that points to the role being used

type RoleRef struct {
    // Kind of the referred role
    // 1. currently "GlobalRole" and "SpaceRole" are supported
    // 2. "GlobalRole" kind ref may be in a GlobalRoleBinding or in a SpaceRoleBinding
    // 3. "SpaceRole" kind ref may only be in a SpaceRoleBinding
    Kind string `json:"kind" yaml:"kind"`
    // Name of the referred role
    Name string `json:"name" yaml:"name"`
}

type ScheduleInterval

type ScheduleInterval struct {
    Interval int `json:"interval" yaml:"interval" bson:"interval"`
    Number   int `json:"number" yaml:"number" bson:"number"`
}

type Secret

Secret is a definition of Secret.

type Secret struct {
    Entity `json:",inline" yaml:",inline" bson:",inline"`
    Spec   SecretSpec   `json:"spec" yaml:"spec"`
    Status SecretStatus `json:"status" yaml:"status"`
    Owner  *Owner       `json:"-" yaml:"-"`
}

type SecretListResult

SecretListResult holds secrets.

type SecretListResult struct {
    Total int      `json:"total" yaml:"total"`
    Items []Secret `json:"items" yaml:"items"`
}

type SecretSpec

SecretSpec is a definition of secret.

type SecretSpec struct {
    // AwsApiAccessKey is a definition of AWS Access Key and Secret.
    AwsApiAccessKey *AwsApiAccessKeySpec `json:"awsApiAccessKey,omitempty" yaml:"awsApiAccessKey,omitempty" bson:"awsApiAccessKey,omitempty"`
    // AzureApiAccessKey is a definition of Azure credentials
    AzureApiAccessKey *AzureApiAccessKey `json:"azureApiAccessKey,omitempty" yaml:"azureApiAccessKey,omitempty" bson:"azureApiAccessKey,omitempty"`
    // GCPApiAccessKey is a definition of GCP credentials
    GCPApiAccessKey *GCPAPIAccessKeySpec `json:"gcpApiAccessKey,omitempty" yaml:"gcpApiAccessKey,omitempty" bson:"gcpApiAccessKey,omitempty"`

    SshPrivateKeySpec *SshPrivateKeySpec `json:"sshPrivateKeySpec,omitempty" yaml:"sshPrivateKeySpec,omitempty" bson:"sshPrivateKeySpec,omitempty"`
    SshKeySpec        *SshKeySpec        `json:"sshKey,omitempty" yaml:"sshKey,omitempty" bson:"sshKey,omitempty"`

    UsernamePasswordSpec *UsernamePasswordSpec `json:"usernamePassword,omitempty" yaml:"usernamePassword,omitempty" bson:"usernamePassword,omitempty"`

    // SpotinstAccessToken is a spec of Spotinst access token.
    // +optional
    SpotinstAccessToken *SpotinstAccessTokenSpec `json:"spotinstAccessToken,omitempty" yaml:"spotinstAccessToken,omitempty", bson:"spotinstAccessToken,omitempty"`
}

type SecretStatus

SecretStatus holds status of the secret.

type SecretStatus struct {
    Status string
}

type SecretStoreSpec

SecretStoreSpec is a spec of secret storage.

type SecretStoreSpec struct {
    Baremetal *BaremetalSecretStoreSpec `json:"baremetal,omitempty" yaml:"baremetal,omitempty"`
    AwsS3     *AwsS3SecretStoreSpec     `json:"awsS3,omitempty" yaml:"awsS3,omitempty"`
    AzureAS   *AzureASSecretStoreSpec   `json:"azureAS,omitempty" yaml:"azureAS,omitempty"`
    GoogleGCS *GoogleGCSSecretStoreSpec `json:"googleGCS,omitempty" yaml:"googleGCS,omitempty"`
}

type SelfHostedClusterLogSinkSpec

SelfHostedClusterLogSinkSpec is a spec for self-hosted cluster wide logging.

type SelfHostedClusterLogSinkSpec struct {
    // Enabled indicates if this sink is enabled.
    Enabled bool `json:"enabled" yaml:"enabled"`
    // Persistent indicates if this sink is persistent.
    Persistent bool `json:"persistent" yaml:"persistent"`
    // Size defines size of the storage, string, must follow k8s resource.Quantity rules.
    Size string `json:"size" yaml:"size"`
    // MasterNodes is the number of master nodes that control the cluster.
    // number of master nodes is must not be 2, need to use 1 or 3 and more
    MasterNodes int `json:"masterNodes" yaml:"masterNodes" bson:"masterNodes"`
    // DataNodes is the number of data nodes that hold data and perform data related operations such as CRUD, search, and aggregations.
    DataNodes int `json:"dataNodes" yaml:"dataNodes" bson:"dataNodes"`
    // ClientNodes is the number of client nodes which serve client requests.
    ClientNodes int `json:"clientNodes" yaml:"clientNodes" bson:"clientNodes"`
}

type SnapshotStatus

ConditionStatus represent status of the condition.

type SnapshotStatus string
const (
    SnapshotStatusPending  SnapshotStatus = SnapshotStatus("Pending")
    SnapshotStatusComplete SnapshotStatus = SnapshotStatus("Completed")
    SnapshotStatusError    SnapshotStatus = SnapshotStatus("Error")
    SnapshotStatusMissing  SnapshotStatus = SnapshotStatus("Missing")
)

type SnapshotTag

type SnapshotTag struct {
    Name  string `json:"name" yaml:"name" bson:"name"`
    Value string `json:"value" yaml:"value" bson:"value"`
}

type Space

Space is environment that delimits the scope of cluster.

type Space struct {
    Entity `json:",inline" yaml:",inline" bson:",inline"`
}

type SpaceListResult

SpaceListResult is a collection of Space

type SpaceListResult struct {
    Total int `json:"total" yaml:"total"`
    // Items is a list of roles
    Items []Space `json:"items" yaml:"items"`
}

type SpaceRole

SpaceRole is in space scope, must be in a specific space

type SpaceRole struct {
    Entity `json:",inline" yaml:",inline" bson:",inline"`
    // Rules holds all the PolicyRules for this Role
    Rules []PolicyRule `json:"rules" yaml:"rules"`
}

type SpaceRoleBinding

SpaceRoleBinding is in space role, must be in a specific space

type SpaceRoleBinding struct {
    Entity `json:",inline" yaml:",inline" bson:",inline"`
    // RoleRef can reference a SpaceRole in the current space or a GlobalRole in the global space.
    RoleRef RoleRef `json:"roleRef" yaml:"roleRef"`
    // Subjects holds references to the objects the role applies to.
    Subjects []Subject `json:"subjects" yaml:"subjects"`
}

type SpaceRoleBindingListResult

SpaceRoleBindingListResult is a collection of SpaceRoleBindings

type SpaceRoleBindingListResult struct {
    Total int `json:"total" yaml:"total"`
    // Items is a list of roleBindings
    Items []SpaceRoleBinding `json:"items" yaml:"items"`
}

type SpaceRoleListResult

SpaceRoleListResult is a collection of SpaceRoles

type SpaceRoleListResult struct {
    Total int `json:"total" yaml:"total"`
    // Items is a list of roles
    Items []SpaceRole `json:"items" yaml:"items"`
}

type SpotinstAccessTokenSpec

SpotinstAccessTokenSpec is a spec for Spotinst Access Token.

type SpotinstAccessTokenSpec struct {
    AccountId   string `json:"accountId" yaml:"accountId" bson:"accountId"`
    AccessToken string `json:"accessToken" yaml:"accessToken" bson:"accessToken"`
}

type SshKeySpec

SshKeySpec is a spec for SSH Key.

type SshKeySpec struct {
    SshPublicKey string `json:"sshPublicKey" yaml:"sshPublicKey"`
}

type SshPrivateKeySpec

SshPrivateKeySpec is a spec for SSH Private Key.

type SshPrivateKeySpec struct {
    SshPrivateKey string `json:"sshPrivateKey" yaml:"sshPrivateKey"`
}

type Subject

Subject contains a reference to the object or user identities a role binding applies to. This can either hold a direct API object reference, or a value for non-objects such as user and group names.

type Subject struct {
    // Kind of object being referenced. Values defined are "User", "Group".
    // If the Authorizer does not recognized the kind value, the Authorizer should report an error.
    Kind string `json:"kind" yaml:"kind"`
    // Name of the object being referenced.
    Name string `json:"name" yaml:"name"`
}

type TypeMeta

TypeMeta describes an individual object in an API response or request with strings representing the type of the object and its API schema version. Structures that are versioned or persisted should inline TypeMeta.

type TypeMeta struct {
    // Kind is a string value representing the REST resource this object represents.
    // Servers may infer this from the endpoint the client submits requests to.
    Kind string `valid:"alphanum,required" json:"kind,omitempty"`

    // APIVersion defines the versioned schema of this representation of an object.
    // Servers should convert recognized schemas to the latest internal value, and
    // may reject unrecognized values.
    APIVersion string `json:"apiVersion,omitempty" yaml:"apiVersion,omitempty"`
}

type User

User holds the information about the user. Information about the user is obtained from the request authentication token

type User struct {
    Id string

    // Username must be unique
    Username string

    // FirstName
    // may be empty
    FirstName *string

    // LastName
    // may be empty
    LastName *string

    // Email
    // may be empty
    Email *string

    // list of roles
    Roles []*Role

    // list of groups
    Groups []string
}

type UsernamePasswordSpec

UsernamePasswordSpec is a spec for Username/Password secret type.

type UsernamePasswordSpec struct {
    Username string `json:"username" yaml:"username" bson:"username"`
    Password string `json:"password" yaml:"password" bson:"password"`
}

type VolumeSnapshot

type VolumeSnapshot struct {
    CreatedAt time.Time `json:"createdAt" yaml:"createdAt" bson:"createdAt"`
    // Size is the size of the volume snapshot, in GiB.
    Size          int64              `json:"size" yaml:"size" bson:"size"`
    Tags          []SnapshotTag      `json:"tags" yaml:"tags" bson:"tags"`
    Aws           *AwsVolumeSnapshot `json:"aws" yaml:"aws" bson:"aws"`
    LocationRef   *string            `json:"locationRef" yaml:"locationRef" bson:"locationRef"`
    Status        SnapshotStatus     `json:"status" yaml:"status" bson:"status"`
    LastCheckTime time.Time          `json:"lastCheckTime" yaml:"lastCheckTime" bson:"lastCheckTime"`
    // PVSpec stores persistence volume object
    PVSpec string `json:"pvspec" yaml:"pvspec" bson:"pvspec"`
    // PVCSpec stores persistence volume claim object
    PVCSpec string `json:"pvcspec" yaml:"pvcspec" bson:"pvcspec"`
}

Constants

const (
    // AWSInstanceGroupLocationSpecGroupTypeASG AWS AutoScaling Group
    AWSInstanceGroupLocationSpecGroupTypeASG = AWSInstanceGroupLocationSpecGroupTypeEnum("asg")

    // AWSInstanceGroupLocationSpecGroupTypeElastiGroup ElastiGroup
    AWSInstanceGroupLocationSpecGroupTypeElastiGroup = AWSInstanceGroupLocationSpecGroupTypeEnum("elastigroup")
)
const (
    // LabelKublrCustomSpecCluster is a 'kublr.io/custom-cluster-spec' label. Available values: 'true', 'false'
    LabelKublrCustomSpecCluster string = "kublr.io/custom-cluster-spec"
    // LabelKublrCloudProvider is a 'kublr.io/cloud-provider' label. Available values: 'aws', 'azure', 'onpremise', 'hybrid'
    LabelKublrCloudProvider = "kublr.io/cloud-provider"
    // LabelKublrClusterRole is "kublr.io/cluster-role" label. Available values: 'platform'
    LabelKublrClusterRole = "kublr.io/cluster-role"
)
const (
    ResourceAll               = "*"
    ResourceSpace             = "space"
    ResourceSecret            = "secret"
    ResourceCluster           = "cluster"
    ResourceBackup            = "backup"
    ResourceGlobalRole        = "globalrole"
    ResourceGlobalRoleBinding = "globalrolebinding"
    ResourceSpaceRole         = "spacesrole"
    ResourceSpaceRoleBinding  = "spacerolebinding"

    GroupKind = "Group"
    UserKind  = "User"

    VerbAll    = "*"
    VerbGet    = "get"
    VerbPut    = "put"
    VerbPost   = "post"
    VerbList   = "list"
    VerbDelete = "delete"

    KindGlobalRole        = "GlobalRole"
    KindGlobalRoleBinding = "GlobalRoleBinding"
    KindSpaceRole         = "SpaceRole"
    KindSpaceRoleBinding  = "SpaceRoleBinding"

    GlobalRoleKublrFullAdmin   = "KublrFullAdmin"
    GlobalRoleKublrDefaultUser = "KublrDefaultUser"
    GlobalRoleKublrReadOnly    = "KublrReadOnly"

    // AutoUpdateAnnotationKey is the name of an annotation which prevents reconciliation if set to "false"
    AutoUpdateAnnotationKey = "rbac.authorization.kublr.com/autoupdate"
)
const (
    // KindSpace is the name of the kind of space
    KindSpace = "Space"
    // SpaceKublrSystem is the system space
    SpaceKublrSystem = "kublr-system"
    // SpaceKublrDefault is the default space
    SpaceKublrDefault = "default"
)
const (
    ROLE_USER   = "user"
    ROLE_ADMIN  = "admin"
    ROLE_SYSTEM = "system"
)
const (
    // KindBackup is constant for Backup Kind.
    KindBackup = "Backup"
)
const (
    // KindBackupConfiguration is constant for BackupConfiguration Kind.
    KindBackupConfiguration = "BackupConfiguration"
)
const (
    // KindCluster is constant for Cluster Kind.
    KindCluster = "Cluster"
)
const (
    // KindEvent is constant for Event Kind.
    KindEvent = "Event"
)
const (
    // KindSecret is constant for Secret Kind.
    KindSecret = "Secret"
)

Questions? Suggestions? Need help? Contact us.