Feature Request: Enable field-level type validation in nomos vet

Đang mở
#2,022 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
35/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
go, kubernetes
Lĩnh vực
devops, testing-qa

Hướng nghiên cứu

Bắt đầu với đường dẫn nomos vet phân tích tài nguyên thành các đối tượng Unstructured, sau đó điều tra cách lấy schema của tài nguyên để xác thực. So sánh việc xác thực phía máy chủ và phía máy khách, bao gồm ví dụ boolean so với string trong ConfigMap. Hoàn tất có nghĩa là nomos vet phát hiện các kiểu không khớp ở cấp trường trước khi tài nguyên đến cluster.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

enhancement
Checklist
  • I did not find a related open enhancement request.
  • I understand that enhancement requests filed in the GitHub repository are by default low priority.
  • If this request is time-sensitive, I have submitted a corresponding issue with GCP support.
Describe the feature

Description: Currently, nomos vet parses objects into Unstructured objects and does not convert them into typed objects. As a result, it does not perform field-level type validation. Users can pass validation with invalid YAML—such as providing a boolean true instead of a string "true" in a ConfigMap—only to encounter sync failures (e.g., KNV2009) when the reconciler attempts to apply the resource.  

Feature request: We request that nomos vet be enhanced to support field-level type validation. The tool should check resource definitions against their schema (server-side or client-side) to catch type mismatches, such as boolean values in string-only fields, before they reach the cluster.  

Alternatives considered:

  • Manual Workarounds: Ensuring all values are explicitly quoted (e.g., "true").  
  • Server-side Dry Run: Running nomos hydrate --flat --clusters=CLUSTER | kubectl apply --dry-run=server -f- to validate rendering and types.  
  • Third-party Tools: Using kubeconform for client-side validation, though this does not handle rendering or server-side checks.
Importance

No response

Ngôn ngữ chính
Go
Star
279
Fork
59
Merge trung bình
10 giờ 23 phút
Pull request đã merge (30 ngày)
9

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của GoogleContainerTools/config-sync

Tất cả issue của GoogleContainerTools/config-sync

Issue tương tự

Thêm issue về Go

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.