Skip to content

Commit

Permalink
Revert "Implement API and CRD for ztunnel component (#481)"
Browse files Browse the repository at this point in the history
This reverts commit 3875a7c.

Signed-off-by: Daniel Grimm <dgrimm@redhat.com>
  • Loading branch information
dgn authored and istio-testing committed Dec 11, 2024
1 parent 41b6819 commit 773a117
Show file tree
Hide file tree
Showing 10 changed files with 3 additions and 11,970 deletions.
8 changes: 0 additions & 8 deletions PROJECT
Original file line number Diff line number Diff line change
Expand Up @@ -43,12 +43,4 @@ resources:
kind: IstioCNI
path: github.com/istio-ecosystem/sail-operator/api/v1alpha1
version: v1alpha1
- api:
crdVersion: v1
namespaced: false
controller: true
domain: sailoperator.io
kind: ZTunnel
path: github.com/istio-ecosystem/sail-operator/api/v1alpha1
version: v1alpha1
version: "3"
107 changes: 0 additions & 107 deletions api/v1alpha1/values_types_extra.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,6 @@

package v1alpha1

import (
k8sv1 "k8s.io/api/core/v1"
)

type SDSConfigToken struct {
Aud string `json:"aud,omitempty"`
}
Expand All @@ -29,106 +25,3 @@ type CNIValues struct {
// Part of the global configuration applicable to the Istio CNI component.
Global *CNIGlobalConfig `json:"global,omitempty"`
}

type ZTunnelValues struct {
// Configuration for the Istio ztunnel plugin.
ZTunnel *ZTunnelConfig `json:"ztunnel,omitempty"`

// Part of the global configuration applicable to the Istio ztunnel component.
Global *ZTunnelGlobalConfig `json:"global,omitempty"`
}

// Configuration for ztunnel.
type ZTunnelConfig struct {
// Hub to pull the container image from. Image will be `Hub/Image:Tag-Variant`.
Hub *string `json:"hub,omitempty"`
// The container image tag to pull. Image will be `Hub/Image:Tag-Variant`.
Tag *string `json:"tag,omitempty"`
// The container image variant to pull. Options are "debug" or "distroless". Unset will use the default for the given version.
Variant *string `json:"variant,omitempty"`
// Image name to pull from. Image will be `Hub/Image:Tag-Variant`.
// If Image contains a "/", it will replace the entire `image` in the pod.
Image *string `json:"image,omitempty"`
// Annotations to apply to all top level resources
Annotations map[string]string `json:"Annotations,omitempty"`
// Labels to apply to all top level resources
Labels map[string]string `json:"Labels,omitempty"`
// Additional volumeMounts to the ztunnel container
VolumeMounts []k8sv1.VolumeMount `json:"volumeMounts,omitempty"`
// Additional volumes to add to the ztunnel Pod.
Volumes []k8sv1.Volume `json:"volumes,omitempty"`
// Annotations added to each pod. The default annotations are required for scraping prometheus (in most environments).
PodAnnotations map[string]string `json:"podAnnotations,omitempty"`
// Additional labels to apply on the pod level.
PodLabels map[string]string `json:"podLabels,omitempty"`
// The k8s resource requests and limits for the ztunnel Pods.
Resources *k8sv1.ResourceRequirements `json:"resources,omitempty"`
// List of secret names to add to the service account as image pull secrets
// to use for pulling any images in pods that reference this ServiceAccount.
// Must be set for any cluster configured with private docker registry.
ImagePullSecrets []string `json:"imagePullSecrets,omitempty"`
// A `key: value` mapping of environment variables to add to the pod
Env map[string]string `json:"env,omitempty"`
// Specifies the image pull policy for the Istio images. one of Always, Never, IfNotPresent.
// Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. Cannot be updated.
//
// More info: https://kubernetes.io/docs/concepts/containers/images#updating-images
// +kubebuilder:validation:Enum=Always;Never;IfNotPresent
ImagePullPolicy *k8sv1.PullPolicy `json:"imagePullPolicy,omitempty"`
// Settings for multicluster.
// The name of the cluster we are installing in. Note this is a user-defined name, which must be consistent
// with Istiod configuration.
MultiCluster *MultiClusterConfig `json:"multiCluster,omitempty"`
// meshConfig defines runtime configuration of components.
// For ztunnel, only defaultConfig is used, but this is nested under `meshConfig` for consistency with other components.
MeshConfig *MeshConfig `json:"meshConfig,omitempty"`
// Configures the revision this control plane is a part of
Revision *string `json:"revision,omitempty"`
// The address of the CA for CSR.
CaAddress *string `json:"caAddress,omitempty"`
// The customized XDS address to retrieve configuration.
XdsAddress *string `json:"xdsAddress,omitempty"`
// Specifies the default namespace for the Istio control plane components.
IstioNamespace *string `json:"istioNamespace,omitempty"`
// Same as `global.logging.level`, but will override it if set
Logging *GlobalLoggingConfig `json:"logging,omitempty"`
// Specifies whether istio components should output logs in json format by adding --log_as_json argument to each container.
LogAsJSON *bool `json:"logAsJSON,omitempty"`
}

// ZTunnelGlobalConfig is a subset of the Global Configuration used in the Istio ztunnel chart.
type ZTunnelGlobalConfig struct { // Default k8s resources settings for all Istio control plane components.
//
// See https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/#resource-requests-and-limits-of-pod-and-container
//
// Deprecated: Marked as deprecated in pkg/apis/values_types.proto.
DefaultResources *k8sv1.ResourceRequirements `json:"defaultResources,omitempty"`

// Specifies the docker hub for Istio images.
Hub *string `json:"hub,omitempty"`
// Specifies the image pull policy for the Istio images. one of Always, Never, IfNotPresent.
// Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. Cannot be updated.
//
// More info: https://kubernetes.io/docs/concepts/containers/images#updating-images
// +kubebuilder:validation:Enum=Always;Never;IfNotPresent
ImagePullPolicy *k8sv1.PullPolicy `json:"imagePullPolicy,omitempty"`
// ImagePullSecrets for the control plane ServiceAccount, list of secrets in the same namespace
// to use for pulling any images in pods that reference this ServiceAccount.
// Must be set for any cluster configured with private docker registry.
ImagePullSecrets []string `json:"imagePullSecrets,omitempty"`

// Specifies whether istio components should output logs in json format by adding --log_as_json argument to each container.
LogAsJSON *bool `json:"logAsJSON,omitempty"`
// Specifies the global logging level settings for the Istio control plane components.
Logging *GlobalLoggingConfig `json:"logging,omitempty"`

// Specifies the tag for the Istio docker images.
Tag *string `json:"tag,omitempty"`
// The variant of the Istio container images to use. Options are "debug" or "distroless". Unset will use the default for the given version.
Variant *string `json:"variant,omitempty"`

// Platform in which Istio is deployed. Possible values are: "openshift" and "gcp"
// An empty value means it is a vanilla Kubernetes distribution, therefore no special
// treatment will be considered.
Platform *string `json:"platform,omitempty"`
}
198 changes: 0 additions & 198 deletions api/v1alpha1/ztunnel_types.go

This file was deleted.

Loading

0 comments on commit 773a117

Please sign in to comment.