entities

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: May 19, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var LabelSelectorAPI = &v1.LabelSelector{
	MatchLabels: map[string]string{
		"anti-affinity-key": "anti-affinity-val",
	},
}
View Source
var LabelSelectorTerraform = []interface{}{
	map[string]interface{}{
		"match_labels": map[string]interface{}{
			"anti-affinity-key": "anti-affinity-val",
		},
	},
}
View Source
var MatchExpressionAPI = []k8sv1.NodeSelectorRequirement{
	{
		Key:      "key",
		Operator: k8sv1.NodeSelectorOperator("operator"),
		Values:   []string{"value1", "value2"},
	},
}
View Source
var MatchExpressionTerraform = []interface{}{
	map[string]interface{}{
		"key":      "key",
		"operator": "operator",
		"values":   utils.NewStringSet(schema.HashString, []string{"value1", "value2"}),
	},
}
View Source
var MatchFieldsAPI = []k8sv1.NodeSelectorRequirement{
	{
		Key:      "key",
		Operator: k8sv1.NodeSelectorOperator("operator"),
		Values:   []string{"value1", "value2"},
	},
}
View Source
var MatchFieldsTerraform = []interface{}{
	map[string]interface{}{
		"key":      "key",
		"operator": "operator",
		"values":   utils.NewStringSet(schema.HashString, []string{"value1", "value2"}),
	},
}
View Source
var NodePreferredDuringSchedulingIgnoredDuringExecution = []interface{}{
	map[string]interface{}{
		"weight":     10,
		"preference": NodeSelectorTermTerraform,
	},
}
View Source
var NodeRequiredDuringSchedulingIgnoredDuringExecution = []interface{}{
	map[string]interface{}{
		"node_selector_term": NodeSelectorTermTerraform,
	},
}
View Source
var NodeSelectorTermAPI = []k8sv1.NodeSelectorTerm{
	{
		MatchExpressions: MatchExpressionAPI,
		MatchFields:      MatchFieldsAPI,
	},
}
View Source
var NodeSelectorTermTerraform = []interface{}{
	map[string]interface{}{
		"match_expressions": MatchExpressionTerraform,
		"match_fields":      MatchFieldsTerraform,
	},
}
View Source
var PodPreferredDuringSchedulingIgnoredDuringExecutionAPI = []k8sv1.WeightedPodAffinityTerm{
	{
		Weight: 100,
		PodAffinityTerm: k8sv1.PodAffinityTerm{
			LabelSelector: &v1.LabelSelector{
				MatchLabels: map[string]string{
					"anti-affinity-key": "anti-affinity-val",
				},
			},
			TopologyKey: "kubernetes.io/hostname",
			Namespaces:  []string{"namespace1"},
		},
	},
}
View Source
var PodPreferredDuringSchedulingIgnoredDuringExecutionTerraform = []interface{}{
	map[string]interface{}{
		"weight": 100,
		"pod_affinity_term": []interface{}{
			map[string]interface{}{
				"label_selector": LabelSelectorTerraform,
				"topology_key":   "kubernetes.io/hostname",
				"namespaces":     utils.NewStringSet(schema.HashString, []string{"namespace1"}),
			},
		},
	},
}
View Source
var PodRequiredDuringSchedulingIgnoredDuringExecutionAPI = []k8sv1.PodAffinityTerm{
	{
		LabelSelector: LabelSelectorAPI,
		TopologyKey:   "kubernetes.io/hostname",
		Namespaces:    []string{"namespace1"},
	},
}
View Source
var PodRequiredDuringSchedulingIgnoredDuringExecutionTerraform = []interface{}{
	map[string]interface{}{
		"label_selector": LabelSelectorTerraform,
		"topology_key":   "kubernetes.io/hostname",
		"namespaces":     utils.NewStringSet(schema.HashString, []string{"namespace1"}),
	},
}

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

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