Skip to Content
Kubernetes编程
book

Kubernetes编程

by Michael Hausenblas, Stefan Schimanski
June 2021
Intermediate to advanced
335 pages
5h 50m
Chinese
China Electric Power Press Ltd.
Content preview from Kubernetes编程
292
9
spec.toppings
中只能包含那些有对应对象的配料。
前两个功能会变更值,第三个功能是纯验证型的。因此,我们需要实现一个
变更
Webhook
和一个验证
Webhook
来满足这些需求。
通过
OpenAPI v3
验证
schema
实现原生的默认值的功能正在开发中。
OpenAPI
提供一个名为
default
的字段,
API
服务器未来会使用这个字段。
另外,丢弃不能被识别的字段会成所有资源的标准行为,由
Kubernetes API
服务器的剪裁机制提供。
剪裁机制在
Kubernetes 1.15
中以
Beta
功能出现。默认值的功能预计在
1.16
版中进入
Beta
。如果在测试集群中已经提供了这两项功能,那前面列表中的
前两项功能就无须再通过
Webhook
来实现了。
9.2.2
准入
Webhook
架构
准入
Webhook
的结构与刚介绍过的转换
Webhook
非常相似。
它们都可以被部署到集群中,通过
Service
443
端口映射到后端提供服务
Pod
的某个端口上,然后通过
admission.k8s.io/v1beta1 API
组中的一个
AdmissionReview
对象来调用。
---
// AdmissionReview describes an admission review request/response.
type AdmissionReview struct {
metav1.TypeMeta `json:",inline"`
// Request describes the attributes ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

解密金融数据

解密金融数据

Justin Pauley
Python机器学习案例精解

Python机器学习案例精解

Posts & Telecom Press, Yuxi (Hayden) Liu
软件开发实践:项目驱动式的Java开发指南

软件开发实践:项目驱动式的Java开发指南

Raoul-Gabriel Urma, Richard Warburton

Publisher Resources

ISBN: 9787519854799