Skip to content

Commit

Permalink
Allow configurable backend modes for aws-iam-authenticator
Browse files Browse the repository at this point in the history
  • Loading branch information
WarpRat committed Jul 5, 2020
1 parent 6a290e7 commit aedfc52
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 0 deletions.
4 changes: 4 additions & 0 deletions k8s/crds/kops.k8s.io_clusters.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,10 @@ spec:
properties:
aws:
properties:
backendMode:
description: BackendMode is the AWS IAM Authenticator backend
to use. Default MountedFile
type: string
cpuLimit:
anyOf:
- type: integer
Expand Down
2 changes: 2 additions & 0 deletions pkg/apis/kops/cluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,8 @@ type KopeioAuthenticationSpec struct {
type AwsAuthenticationSpec struct {
// Image is the AWS IAM Authenticator docker image to use
Image string `json:"image,omitempty"`
// BackendMode is the AWS IAM Authenticator backend to use. Default MountedFile
BackendMode string `json:"backendMode,omitempty"`
// MemoryRequest memory request of AWS IAM Authenticator container. Default 20Mi
MemoryRequest *resource.Quantity `json:"memoryRequest,omitempty"`
// CPURequest CPU request of AWS IAM Authenticator container. Default 10m
Expand Down
2 changes: 2 additions & 0 deletions pkg/apis/kops/v1alpha2/cluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -300,6 +300,8 @@ type KopeioAuthenticationSpec struct {
type AwsAuthenticationSpec struct {
// Image is the AWS IAM Authenticator docker image to uses
Image string `json:"image,omitempty"`
// BackendMode is the AWS IAM Authenticator backend to use. Default MountedFile
BackendMode string `json:"backendMode,omitempty"`
// MemoryRequest memory request of AWS IAM Authenticator container. Default 20Mi
MemoryRequest *resource.Quantity `json:"memoryRequest,omitempty"`
// CPURequest CPU request of AWS IAM Authenticator container. Default 10m
Expand Down
2 changes: 2 additions & 0 deletions pkg/apis/kops/v1alpha2/zz_generated.conversion.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions upup/models/bindata.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ spec:
- --config=/etc/aws-iam-authenticator/config.yaml
- --state-dir=/var/aws-iam-authenticator
- --kubeconfig-pregenerated=true
- --backend-mode={{ or .Authentication.Aws.BackendMode "MountedFile" }}

resources:
requests:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ spec:
- --config=/etc/aws-iam-authenticator/config.yaml
- --state-dir=/var/aws-iam-authenticator
- --kubeconfig-pregenerated=true
- --backend-mode={{ or .Authentication.Aws.BackendMode "MountedFile" }}

resources:
requests:
Expand Down

0 comments on commit aedfc52

Please sign in to comment.