Skip to content

Commit 2a81120

Browse files
committed
Fixes for smooth ArgoCD uninstall
1 parent 983e9a9 commit 2a81120

File tree

5 files changed

+12
-7
lines changed

5 files changed

+12
-7
lines changed

deployments/liqo/templates/pre-delete-job.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ metadata:
77
labels:
88
{{- include "liqo.labels" $predelete| nindent 4 }}
99
annotations:
10+
argocd.argoproj.io/hook: PreSync
1011
{{- include "liqo.preDeleteAnnotations" $predelete| nindent 4 }}
1112
spec:
1213
template:

deployments/liqo/templates/pre-delete-rbac.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@ metadata:
77
labels:
88
{{- include "liqo.labels" $predelete| nindent 4 }}
99
annotations:
10-
{{- include "liqo.preDeleteAnnotations" $predelete| nindent 4 }}
10+
argocd.argoproj.io/hook: PreSync
11+
{{- include "liqo.preDeleteAnnotations" $predelete| nindent 4 }}
1112
---
1213
apiVersion: rbac.authorization.k8s.io/v1
1314
kind: ClusterRoleBinding

pkg/consts/labels.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,12 @@ const (
3838
// APIServerProxyAppName label value that denotes the name of the liqo-api-server-proxy deployment.
3939
APIServerProxyAppName = "proxy"
4040

41+
// OffloadingComponentKey is the label assigned to the Liqo components related to offloading.
42+
OffloadingComponentKey = "offloading.liqo.io/component"
43+
44+
// NetworkingComponentKey is the label assigned to the Liqo components related to networking.
45+
NetworkingComponentKey = "networking.liqo.io/component"
46+
4147
// IpamStorageResourceLabelKey is the constant representing
4248
// the key of the label assigned to all IpamStorage resources.
4349
IpamStorageResourceLabelKey = "ipam.liqo.io/ipamstorage"

pkg/gateway/label.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,15 @@
1515
package gateway
1616

1717
import (
18+
"github.com/liqotech/liqo/pkg/consts"
1819
"github.com/liqotech/liqo/pkg/firewall"
1920
"github.com/liqotech/liqo/pkg/gateway/concurrent"
2021
"github.com/liqotech/liqo/pkg/route"
2122
)
2223

2324
const (
2425
// GatewayComponentKey is the key used to label the gateway pod.
25-
GatewayComponentKey = "networking.liqo.io/component"
26+
GatewayComponentKey = consts.NetworkingComponentKey
2627

2728
// GatewayComponentGateway is the key used to label the gateway pod.
2829
GatewayComponentGateway = "gateway"

pkg/vkMachinery/const.go

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,7 @@ const CRBPrefix = "liqo-node-"
3030

3131
// KubeletBaseLabels are the static labels that are set on every VirtualKubelet.
3232
var KubeletBaseLabels = map[string]string{
33-
consts.K8sAppNameKey: "virtual-kubelet",
34-
consts.K8sAppInstanceKey: "virtual-kubelet",
35-
consts.K8sAppManagedByKey: consts.LiqoAppLabelValue,
36-
consts.K8sAppComponentKey: "virtual-kubelet",
37-
consts.K8sAppPartOfKey: "liqo",
33+
consts.OffloadingComponentKey: "virtual-kubelet",
3834
}
3935

4036
// ClusterRoleBindingLabels are the static labels that are set on every ClusterRoleBinding managed by Liqo.

0 commit comments

Comments
 (0)