datashim
datashim copied to clipboard
DLF labels are having conflicts with Istio sidecar Injection
When trying to deploy a pod with DLF labels inside an namespace with istio inject, I'm seeing the errors below. It looks like there's some conflicts between the DLF and istio mutation.
The Pod "nginx" is invalid: spec.volumes[4].name: Duplicate value: "example-dataset"
Here is my pod
cat <<EOF | kubectl apply -f -
apiVersion: v1
kind: Pod
metadata:
name: nginx
namespace: default
labels:
dataset.0.id: "example-dataset"
dataset.0.useas: "mount"
spec:
containers:
- name: nginx
image: nginx
EOF
Hi @Tomcli can you try creating the pod like this:
cat <<EOF | kubectl apply -f -
apiVersion: v1
kind: Pod
metadata:
name: nginx
annotations:
sidecar.istio.io/inject: "false"
namespace: default
labels:
dataset.0.id: "example-dataset"
dataset.0.useas: "mount"
spec:
containers:
- name: nginx
image: nginx
EOF
Thanks @YiannisGkoufas, for pipelines we can disable istio sidecar. On the notebook server we can define our own volume mount definition on the UI so we can bypass this problem. But on KFServing, if we are going to disable istio sidecar, then we are losing some traffic metrics. Although those metrics are not important for now, we should revisit it in the future as there could be other mutation webhook that can cause this problem.
Hi @Tomcli can you try creating the pod like this:
cat <<EOF | kubectl apply -f - apiVersion: v1 kind: Pod metadata: name: nginx annotations: sidecar.istio.io/inject: "false" namespace: default labels: dataset.0.id: "example-dataset" dataset.0.useas: "mount" spec: containers: - name: nginx image: nginx EOF
@YiannisGkoufas we can put this into a troubleshooting section and close this issue.
Closing this issue as it seems to have been resolved