- 最新
- 投票最多
- 评论最多
In your YAML configuration, there are syntax errors such as missing commas between elements in the JSON array and incorrect indentation. Additionally, the JSON format should be properly formatted within the YAML file
Could you please correct your Yaml config and try again
apiVersion: v1
kind: ConfigMap
metadata:
name: kubecost-configmap
data:
example-json-file: |
{
"containers": [
{
"name": "aggregated",
"resources": {
"limits": {
"cpu": "2000m",
"memory": "2Gi"
},
"requests": {
"cpu": "1000m",
"memory": "1Gi"
}
}
},
{
"name": "cloud-cost",
"resources": {
"limits": {
"cpu": "2000m",
"memory": "2Gi"
},
"requests": {
"cpu": "1000m",
"memory": "1Gi"
}
}
}
]
}
Make sure to adjust the configuration according to the requirements and schema expected by the Kubecost addon. Additionally, ensure that you have proper permissions and access policies to create the addon in your EKS cluster. You can find some useful info here :- https://github.com/kubecost/kubecost-eks-blueprints-addon
@Adeleke Adebowale J We have removed the indentations and formatted the JSON but still getting the same error. An error occurred (InvalidParameterException) when calling the CreateAddon operation: ConfigurationValue provided in request is not supported: Json schema validation failed with error:
"DENY: missing spec.containers[].resources.limits.cpu kubecost/cost-analyzer container; aggregator: DENY: missing spec.containers[].resources.limits.cpu kubecost/cost-analyzer container; cloud-cost" }
Can you help us how can we configure the values for above missing CPU limits for containers that could help in creating add-on. We tried multiple ways but getting the same schema validation failed.
We corrected the yaml file we applied the yaml file still we are facing the same issue apiVersion: v1 kind: ConfigMap metadata: name: kubecost-configmap data: configuration.yaml: | containers: - name: aggregator resources: limits: cpu: "2000m" memory: "2Gi" requests: cpu: "1000m" memory: "1Gi" - name: cloud-cost resources: limits: cpu: "2000m" memory: "2Gi" requests: cpu: "1000m" memory: "1Gi"
" [$.kubecostAggregator: is not defined in the schema and the schema does not allow additional properties] The error message indicates that the kubecostAggregator property is not defined in the schema. This suggests that the kubecostAggregator property is not recognized or expected in the configuration. Make sure you are using the correct property names and schema for the Kubecost addon configuration