Closed ryanw666 closed 7 months ago
Hi @ryanw666 thanks for the report.
I suppose you're deploying DevWorkspace Operator to some AWS hosted Kubernetes cluster correct? Do you mind providing more info on your environment? My best guess is the AWS platform is adding the aws-iam-authenticator:281621839170:AROAUDEPYHVBAYNDFMTJV
label which is breaking things (though I'm not sure why this is being added).
By any chance, if you try deploying a pod to your cluster such as the following (by saving this YAML to a file and doing a kubectl apply -f <filename>
) do you get a similar error about a metadata.label?:
apiVersion: v1
kind: Pod
metadata:
name: nginx
spec:
containers:
- name: nginx
image: nginx:1.14.2
ports:
- containerPort: 80
Lastly, have you tried creating a dedicated namespace for deploying your devworkspace? In the kubectl command you gave, you are deploying the devworkspace to the default namespace. Perhaps you need to deply your devworksapce to another namespace to prevent the aws-iam-authenticator
label from being added? e.g. kubectl apply -f samples/code-latest.yaml -n <your-namespace>
Thanks for your response. I am indeed deploying this on an AWS-hosted kubernetes cluster, but deploying the nginx pod you suggest goes through without errors and no metadata.labels
appears.
I tried just now deploying it in its own workspace (kubectl apply -f samples/code-latest.yaml -n my-namespace
) but got the same error.
Let me know if there's any other useful information I could provide.
Ah! I have found that it works if I deploy the devworkspace operator to a local kind
cluster instead of to AWS. So it's something particular to AWS.
@ryanw666 I'm glad to hear you figured out the issue!
I just followed the instructions in the readme to deploy devworkspace operator to a cluster. Then when I tried to run
kubectl apply -f samples/code-latest.yaml
, I get:I'm baffled because there's no
metadata.labels
in that file; it's literally just the file from this repository. Would appreciate any ideas on what could be causing this.Devworkspace operator version: 8f3eafb9 (main branch as of posting) Cluster kubernetes version: v1.28.5-eks-5e0fdde