Commit Graph

101 Commits

Author SHA1 Message Date
Clayton Coleman fcc6b93d70 Load initializers from dynamic config
Handle failure cases on startup gracefully to avoid causing cascading
errors and poor initialization in other components. Initial errors from
config load cause the initializer to pause and hold requests. Return
typed errors to better communicate failures to clients.

Add code to handle two specific cases - admin wants to bypass
initialization defaulting, and mirror pods (which want to bypass
initialization because the kubelet owns their lifecycle).

Kubernetes-commit: 772ab8e1b4163c17d285a2789321762a8f2dc9f3
2017-06-13 20:47:31 +00:00
Jordan Liggitt 8ab96afbb9 Avoid * in filenames
Kubernetes-commit: b5e5e93201ccbc1b4ed1da0378c1f550508bfc4f
2017-06-13 20:47:31 +00:00
mbohlool 0bd6ffe372 Update Bazel
Kubernetes-commit: c2f2a33dc51e33634317dcc125543d3d05dab500
2017-06-13 20:47:31 +00:00
mbohlool f03a4943d7 Aggregate OpenAPI specs
Kubernetes-commit: 1a1d9a0394cbdb1d1e2412ae8f0157799eb5329c
2017-06-13 20:47:31 +00:00
mbohlool f10f5391f1 Separate Build and Serving parts of OpenAPI spec handler
Kubernetes-commit: 0a886ffaf8b9de97ef8134a4182b719ba2c6f22f
2017-06-13 20:47:31 +00:00
mbohlool bfb371141a Remove unused servePath from GetOperationIDAndTags and GetDefinitionName
Kubernetes-commit: ef8ee84cd07dedf0a441d455f54b55a6468b4b3d
2017-06-13 20:47:31 +00:00
Clayton Coleman 5fa08b8c5e Allow initialization of resources
Add support for creating resources that are not immediately visible to
naive clients, but must first be initialized by one or more privileged
cluster agents. These controllers can mark the object as initialized,
allowing others to see them.

Permission to override initialization defaults or modify an initializing
object is limited per resource to a virtual subresource "RESOURCE/initialize"
via RBAC.

Initialization is currently alpha.

Kubernetes-commit: 331eea67d8000e5c4b37e2234a90903c15881c2f
2017-06-13 20:47:30 +00:00
Saksham Sharma 0b1c13686c Add configuration options for encryption providers
Add location transformer, config for transformers

Location transformer helps choose the most specific transformer for
read/write operations depending on the path of resource being accessed.

Configuration allows use of --experimental-encryption-provider-config
to set up encryption providers. Only AEAD is supported at the moment.

Add new files to BUILD, AEAD => k8s-aes-gcm

Use group resources to select encryption provider

Update tests for configuration parsing

Remove location transformer

Allow specifying providers per resource group in configuration

Add IdentityTransformer configuration option

Fix minor issues with initial AEAD implementation

Unified parsing of all configurations

Parse configuration using a union struct

Run configuration parsing in APIserver, refactor parsing

More gdoc, fix minor bugs

Add test coverage for combined transformers

Use table driven tests for encryptionconfig

Kubernetes-commit: 9760d00d08ef0619e30a7b1b90fd290cab960069
2017-06-13 20:47:30 +00:00
Jordan Liggitt efae6ed84b Pre-generate SNI test certs
Kubernetes-commit: 6554dfc4456869e299b8f6a8f686e8c3cee073d9
2017-06-13 20:47:30 +00:00
Dr. Stefan Schimanski d6f1990c7c apiserver: avoid resolving 'localhost'
The golang stdlib resolve localhost first via the external DNS server,
not via /etc/hosts. If your DNS resolve localhost.<search-domain>, the
API server won't start.

Kubernetes-commit: 63cd572c74a40933d8e6928e084601810b724a81
2017-06-13 20:47:30 +00:00
Eric Chiang be1a712a68 apiserver: add a webhook implementation of the audit backend
Kubernetes-commit: a88e0187f9f6083ed68d18e939a776c44c728e4b
2017-06-13 20:47:30 +00:00
p0lyn0mial 42d367c84c register all generic admission plugins when AdmissionOptions are created.
lifecycle plugin: make use of the libraries under k8s.io/client-go/pkg/api and k8s.io/client-go/kubernetes
for the client libraries instead of k8s.io/kubernetes/client/*

move registration to AdmissionOptions

Kubernetes-commit: 77eb2f39500f1fcf66899ea557791e7bca851449
2017-06-13 20:47:29 +00:00
deads2k 10de73bc53 move CRD behind TPR
Kubernetes-commit: 18177e2bdeafbddeb3d66fec0b8cb88794cd69ff
2017-06-13 20:47:29 +00:00
Tim St. Clair 8ff532a4cb Implement audit policy logic
Kubernetes-commit: a5de309ee261aea15bb1cc12647b32640c2ac196
2017-06-13 20:47:28 +00:00
p0lyn0mial ecba80695f remove init blocks from all admission plugins
Kubernetes-commit: c5019bf6962475ffff94ef4993bdc651b79f650c
2017-06-13 20:47:28 +00:00
Dr. Stefan Schimanski 94ea219615 Update bazel
Kubernetes-commit: 9fdc36a47ada0bc34ee53b68edd085d368ed9012
2017-06-13 20:47:28 +00:00
Dr. Stefan Schimanski ec8d130fa7 audit: wire through non-nil context everywhere
Kubernetes-commit: ce942d19c378ecd335e7e158e30cdc184f9d6184
2017-06-13 20:47:28 +00:00
Dr. Stefan Schimanski f7d766d92d audit: add audit event to the context and fill in handlers
Kubernetes-commit: 0b5bcb021932355b3ff7c2b45fb579f4adad84bf
2017-06-13 20:47:28 +00:00
Dr. Stefan Schimanski 6bd3c73150 apiserver: move LongRunningRequestCheck type into endpoints/request
Kubernetes-commit: c1bf6e832e2887ef6cd0e7b7fa97a168fdf474e5
2017-06-13 20:47:27 +00:00
deads2k 283dd09ef7 tighten and simplify owners in some staging repos
Kubernetes-commit: e7871dbab26459163fd916b83563c4815c7ca43c
2017-06-13 20:47:27 +00:00
mbohlool 032de8d661 Update bazel
Kubernetes-commit: 4d4abf3ba625488bd8a1b577f15b85db3c0fccac
2017-05-21 17:28:01 +00:00
mbohlool e57f74f648 bugfix: form parameters should have type in OpenAPI spec
Kubernetes-commit: 4b0fbfe1ee23e5498ecc4786d3eeec222710473b
2017-05-21 17:28:01 +00:00
mbohlool d5a4874935 Add protobuf binary version of openapi spec
Kubernetes-commit: 161b480107d94fae0373a2d7221413ec7a816229
2017-05-21 17:28:01 +00:00
p0lyn0mial b10e93e2f5 bazel update
Kubernetes-commit: 7b0950b298c876668d469d4b5b2ad7a4dcd344fc
2017-05-16 17:27:51 +00:00
p0lyn0mial ceeef3670c This PR implements AdmissionOptions.ApplyTo
ApplyTo adds the admission chain to the server configuration the method lazily initializes a generic plugin
that is appended to the list of pluginInitializers.

apiserver.Config will hold an instance of SharedInformerFactory to ensure we only have once instance.
The field will be initialized in apisever.SecureServingOptions

Kubernetes-commit: 8cea69aa9812d6627ebdfa4f8b9c1d7624a8f3f5
2017-05-16 17:27:50 +00:00
deads2k 00b83db9b8 plumb stopch to post start hook index since many of them are starting go funcs
Kubernetes-commit: be39283923650ad96539640ca988fbf194db2be4
2017-05-12 17:30:09 +00:00
Nail Islamov f72563011c Remove mentioning insecure server (which is not supported anymore)
Kubernetes-commit: 6c448319ac4b6e05db87b126db136c609eceec55
2017-05-12 17:30:09 +00:00
deads2k 49f3eb05d8 refactor names for the apiserver handling chain
Kubernetes-commit: 4389f715768661731f0aae7438b2cc8414c9746a
2017-05-12 17:30:09 +00:00
Dr. Stefan Schimanski 234a9303e9 apiserver: tri-state watch cache capacity: off, default, value
Kubernetes-commit: b799e62e1aa82a1f1ff87597e762734cd702cdee
2017-05-12 17:30:09 +00:00
mbohlool 1ce699c0dd Add GroupVersionKind and Action extensions to OpenAPI operations
Kubernetes-commit: fca7003dc5bd122e2123ef260e8612663f74a65b
2017-05-12 17:30:09 +00:00
mbohlool a44fceadf3 Update go-restful dependency
Kubernetes-commit: ea042c6ca0fc7eb8017012ca56d6879b8cf10637
2017-05-12 17:30:08 +00:00
Dr. Stefan Schimanski e640e78936 apiserver: fix --tls-sni-cert-key doc string
Kubernetes-commit: 53365880086f0d0d53002de7ce816284da41f4d0
2017-05-12 17:30:08 +00:00
Cao Shufeng ec0ac3b1aa update the doc of function NewPathRecorderMux
Kubernetes-commit: 8b54081939c400d904dbf02fe5143c9dc11ad0ac
2017-05-12 17:30:08 +00:00
mbohlool 0a32c6d3e2 Fix yet another bug in OpenAPI extension generation
Kubernetes-commit: bcd0288e607ee1a1eba3d69dbb7d533f7ef2e4ba
2017-05-05 20:36:47 +00:00
deads2k 585812f439 use our own serve mux that directs how we want
Kubernetes-commit: c837c7fb1a227ef8c772ad15b08ff47593379543
2017-05-04 20:36:37 +00:00
deads2k 2b31ba8b9c separate discovery from the apiserver
Kubernetes-commit: e099f5eee60ad32661d28a2eda9d615ac25ba9a4
2017-05-02 20:36:05 +00:00
xiangpengzhao 1512c30ca6 Delete "hard-coded" default value in flags usage.
Kubernetes-commit: 420caf200cdb1ba41d6af43c5695c29de2082851
2017-04-29 20:35:54 +00:00
zhouhaibing089 79f762de77 componentstatus: support client cert health check
etcd has support for client-cert-auth, which can be configured via the flag `--ca-file`,
when that is enabled, all the client requests must present with a client certificate,
however, the current component status check uses a single transport for all of the checks,
this is wrong, the checks should be different for each of different component, and make
each of them use different transport(tls configurations).

Kubernetes-commit: b1040171b68217dccb617de85defa4a5063c638b
2017-04-22 20:36:06 +00:00
p0lyn0mial fdb6bac0df bazel update
Kubernetes-commit: 4a3dcff3bfb49317cee8fb209f6b915fc9e82f1a
2017-04-21 20:35:37 +00:00
p0lyn0mial 3422dafac7 Split out AdmissionOptions
In the long term AdmissionOptions will accepts various dependencies
and spit out AdmissionControl

Kubernetes-commit: de9706bc15ffc3a6a4ef30a00d5c7ea9a8881396
2017-04-21 20:35:37 +00:00
Maru Newby 6c1b74403d apiserver: Update genericapiserver to panic on listener error
Previously runServer would try to listen again if a listener error
occurred.  This commit changes the response to a panic to allow a
process manager (systemd/kubelet/etc) to react to the failure.

Kubernetes-commit: 30fb3be4d29179cf551e3030ade37d94d9acc8c9
2017-04-20 20:35:32 +00:00
Christoph Blecker 6d6242ff50 Fix gofmt errors
Kubernetes-commit: 6681835b0c00122a408bd4addd47b02840b6208c
2017-04-18 20:35:41 +00:00
Mike Danese 2aab760a2a autogenerated
Kubernetes-commit: a05c3c0efdc5822049e34b1a5a1ee259c5fb1906
2017-04-15 20:35:23 +00:00
deads2k 631ed9acef add deregistration for paths
Kubernetes-commit: cd950364e5259659a771caf5b564de7a8319969b
2017-04-13 20:35:21 +00:00
Dr. Stefan Schimanski 320e34b1d9 pkg/admission: make plugin registry non-global
Kubernetes-commit: 63f547e1b15ed94ef91c69a7e294b3506bd8c918
2017-04-12 20:35:22 +00:00
mbohlool f8217a24e4 Bugfix: OpenAPI generator should pass generate type extensions
Kubernetes-commit: ab5bcf6d2da5fc9cd2374e966f87e20a95d59ed6
2017-04-12 20:35:22 +00:00
deads2k 01f14fece5 only log stacks on server errors
Kubernetes-commit: b73cddb2278d792c7e07d4e69969df32636ecb6d
2017-04-10 20:35:11 +00:00
Jordan Liggitt 72998a2b11 Allow disabling specific post-start hooks
Kubernetes-commit: 2c89ff59e22e0d9c825203c4cb94613a3b246d64
2017-03-31 20:37:16 +00:00
Jordan Liggitt b137e92ccf Plumb cipher/tls version serving options
Kubernetes-commit: e156aca4f21331465ba9406be362b9f16b8aba9e
2017-03-31 20:37:15 +00:00
Jordan Liggitt 1d9d56a19e Update godoc for discovery registration
Kubernetes-commit: 85b23bb98a2c80fe631e20785e5e7172cb69e518
2017-03-31 20:37:15 +00:00