Update swift e2e to use CNS ds with CNI installer (#1501)
* use initContainers * add suggested changes * add vni-conflist to volumes * test w diff region * modify deploy args * fix deploy args Co-authored-by: Camryn Lee <camrynlee@microsoft.com>
This commit is contained in:
Родитель
a6d78a7e1a
Коммит
3a854f5766
|
@ -47,7 +47,7 @@ steps:
|
|||
sudo install -o root -g root -m 0755 kubectl /usr/local/bin/kubectl
|
||||
kubectl cluster-info
|
||||
kubectl get po -owide -A
|
||||
sudo -E env "PATH=$PATH" VERSION=$(Tag) INSTALL_CNI=true INSTALL_CNS=true make test-integration
|
||||
sudo -E env "PATH=$PATH" VERSION=$(Tag) INSTALL_CNS=true make test-integration
|
||||
retryCountOnTaskFailure: 3
|
||||
name: "aksswifte2e"
|
||||
displayName: "Run AKS Swift E2E"
|
||||
|
|
|
@ -73,8 +73,29 @@ spec:
|
|||
fieldRef:
|
||||
apiVersion: v1
|
||||
fieldPath: spec.nodeName
|
||||
initContainers:
|
||||
- name: init-cni-dropgz
|
||||
image: acnpublic.azurecr.io/cni-dropgz:v1.4.28-41-g3ecb7fb1
|
||||
imagePullPolicy: Always
|
||||
command: ["./dropgz"]
|
||||
args: [
|
||||
"deploy",
|
||||
"azure-vnet",
|
||||
"-o", "/opt/cni/bin/azure-vnet",
|
||||
"azure-linux-swift.conflist",
|
||||
"-o", "/etc/cni/net.d/10-azure.conflist"]
|
||||
imagePullPolicy: Always
|
||||
volumeMounts:
|
||||
- name: cni-bin
|
||||
mountPath: /opt/cni/bin
|
||||
- name: cni-conflist
|
||||
mountPath: /etc/cni/net.d
|
||||
hostNetwork: true
|
||||
volumes:
|
||||
- name: cni-conflist
|
||||
hostPath:
|
||||
path: /etc/cni/net.d
|
||||
type: Directory
|
||||
- name: log
|
||||
hostPath:
|
||||
path: /var/log
|
||||
|
|
|
@ -123,6 +123,8 @@ func installCNSDaemonset(ctx context.Context, clientset *kubernetes.Clientset, i
|
|||
|
||||
image, _ := parseImageString(cns.Spec.Template.Spec.Containers[0].Image)
|
||||
cns.Spec.Template.Spec.Containers[0].Image = getImageString(image, imageTag)
|
||||
initImage, _ := parseImageString(cns.Spec.Template.Spec.InitContainers[0].Image)
|
||||
cns.Spec.Template.Spec.InitContainers[0].Image = getImageString(initImage, imageTag)
|
||||
cnsDaemonsetClient := clientset.AppsV1().DaemonSets(cns.Namespace)
|
||||
|
||||
log.Printf("Installing CNS with image %s", cns.Spec.Template.Spec.Containers[0].Image)
|
||||
|
|
Загрузка…
Ссылка в новой задаче