You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: vcluster/configure/vcluster-yaml/sync/from-host/ingress-classes.mdx
+10-10Lines changed: 10 additions & 10 deletions
Original file line number
Diff line number
Diff line change
@@ -44,13 +44,13 @@ If you try to create an IngressClass directly in the virtual cluster, using for
44
44
45
45
When IngressClass sync is enabled, vCluster uses selector criteria to control which resources are synced between clusters. This affects two different resource types that flow in opposite directions.
46
46
47
-
- **IngressClass resources**: Flow from host cluster to virtual cluster only. You cannot create IngressClass resources in the virtual cluster. vCluster copies IngressClass resources from the host cluster based on your selector criteria to make them available for you to reference in their Ingress configurations. If no `selector` is specified, all IngressClass resources from the host cluster are synced.
47
+
- **IngressClass resources (host → virtual)**: Flow from host cluster to virtual cluster only. You cannot create IngressClass resources in the virtual cluster. vCluster copies IngressClass resources from the host cluster based on your selector criteria to make them available for you to reference in their Ingress configurations. If no `selector` is specified, all IngressClass resources from the host cluster are synced.
48
48
49
-
- **Ingress resources**: Flow from virtual cluster to host cluster where ingress controllers process them. An Ingress syncs only if it references an IngressClass that matches your selector criteria. Ingress resources also sync if they have an empty `ingressClassName` field or if no `selector` is specified in the configuration - this works as a bypass mechanism.
49
+
- **Ingress resources (virtual → host)**: Flow from virtual cluster to host cluster where ingress controllers process them. An Ingress syncs only if it references an IngressClass that matches your selector criteria. Ingress resources also sync if they have an empty `ingressClassName` field or if no `selector` is specified in the configuration.
50
50
51
51
- **How selectors control both flows**: The selector determines which IngressClass resources get copied from host to virtual cluster. The same selector also determines which Ingress resources can sync from virtual to host cluster. If an Ingress references an IngressClass that wasn't synced to the virtual cluster, that Ingress cannot sync to the host cluster.
52
52
53
-
## Using selectors to filter IngressClasses
53
+
## Use selectors to filter IngressClasses
54
54
55
55
Selectors provide precise control over which IngressClass resources get synced from the host cluster. vCluster supports two types of selector criteria that follow standard Kubernetes label selector syntax.
56
56
@@ -65,9 +65,9 @@ The `matchExpressions` selector allows more flexible, set-based filtering with s
65
65
66
66
All specified label conditions must match for an IngressClass to be included in the sync. This means that if you define both `matchLabels` and `matchExpressions`, an IngressClass must satisfy all criteria to be synced to the virtual cluster.
67
67
68
-
## Sync behavior and considerations
68
+
## Sync behavior considerations
69
69
70
-
### Resource lifecycle and validation
70
+
### Resource lifecycle
71
71
72
72
Synced IngressClass resources function like any other Kubernetes resource in the virtual cluster. You can view them with `kubectl get ingressclass` and reference them in your Ingress specifications. When you modify an IngressClass in the host cluster, vCluster re-evaluates whether it still matches the selector criteria. If the IngressClass continues to match, vCluster updates the corresponding resource in the virtual cluster to reflect the changes. If the IngressClass no longer matches the selector criteria, vCluster removes it from the virtual cluster.
73
73
@@ -85,7 +85,7 @@ When you creates an Ingress resource that references an IngressClass not matchin
85
85
86
86
The error output appears as a Kubernetes event that you can view using `kubectl describe`. The event message clearly states that the ingress was not synced because the referenced IngressClass does not match the configured selector criteria.
87
87
88
-
### Orphaned resources and cleanup
88
+
### Remove orphaned resources
89
89
90
90
When vCluster removes a synced IngressClass from the virtual cluster due to selector changes or deletion from the host cluster, any Ingress resources that reference it remain in the virtual cluster. These orphaned Ingress resources stop receiving updates but vCluster does not automatically delete them to prevent unintended data loss. To remove these orphaned resources, you must delete them manually in the host cluster. This manual approach ensures that you maintain full control over resource cleanup and can verify that deletions are intentional.
91
91
@@ -95,7 +95,7 @@ When vCluster removes a synced IngressClass from the virtual cluster due to sele
95
95
96
96
To sync only IngressClass resources labeled `environment: development`:
97
97
98
-
```yaml title="Filter example ingressClass"
98
+
```yaml title="Filter example IngressClass"
99
99
sync:
100
100
toHost:
101
101
ingresses:
@@ -112,7 +112,7 @@ sync:
112
112
113
113
To sync IngressClass resources where the label `kubernetes.io/ingress.class` is either `nginx` or `traefik`:
114
114
115
-
```yaml title="Flexible filter example ingressClass"
115
+
```yaml title="Flexible filter example IngressClass"
116
116
sync:
117
117
toHost:
118
118
ingresses:
@@ -133,7 +133,7 @@ sync:
133
133
134
134
The following configuration syncs IngressClass resources that match both label and expression criteria:
135
135
136
-
```yaml title="Combined filter example ingressClass"
136
+
```yaml title="Combined filter example IngressClass"
137
137
sync:
138
138
toHost:
139
139
ingresses:
@@ -156,7 +156,7 @@ sync:
156
156
157
157
When an Ingress resource references an IngressClass that doesn't match the selector criteria, the error output looks like this:
158
158
159
-
```bash title"Error handling example ingressClass"
159
+
```bash title"Error handling example IngressClass"
0 commit comments