-
Notifications
You must be signed in to change notification settings - Fork 54
Add OIDC Federation Settings #479
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
5f7551f
ea56a81
5404ccf
113bf35
ed85d5b
e53f4aa
065c0c8
1af3f65
f89b3a9
f313487
695fd14
60d6883
44bd8f7
48d040f
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -132,8 +132,8 @@ type KeystoneAPISpecCore struct { | |
| FernetMaxActiveKeys *int32 `json:"fernetMaxActiveKeys"` | ||
|
|
||
| // +kubebuilder:validation:Optional | ||
| // +kubebuilder:default={admin: AdminPassword} | ||
| // PasswordSelectors - Selectors to identify the AdminUser password from the Secret | ||
| // +kubebuilder:default={admin: AdminPassword, keystoneOIDCClientSecret: KeystoneOIDCClientSecret, keystoneOIDCCryptoPassphrase: KeystoneOIDCCryptoPassphrase} | ||
| // PasswordSelectors - Selectors to identify the AdminUser, KeystoneOIDCClient, and KeystoneOIDCCryptoPassphrase passwords from the Secret | ||
| PasswordSelectors PasswordSelector `json:"passwordSelectors"` | ||
|
|
||
| // +kubebuilder:validation:Optional | ||
|
|
@@ -184,6 +184,10 @@ type KeystoneAPISpecCore struct { | |
| // +operator-sdk:csv:customresourcedefinitions:type=spec | ||
| // TLS - Parameters related to the TLS | ||
| TLS tls.API `json:"tls,omitempty"` | ||
|
|
||
| // +kubebuilder:validation:Optional | ||
| // +OIDCFederation - parameters to configure keystone for OIDC federation | ||
| OIDCFederation *KeystoneFederationSpec `json:"oidcFederation,omitempty"` | ||
| } | ||
|
|
||
| // APIOverrideSpec to override the generated manifest of several child resources. | ||
|
|
@@ -199,6 +203,79 @@ type PasswordSelector struct { | |
| // +kubebuilder:default="AdminPassword" | ||
| // Admin - Selector to get the keystone Admin password from the Secret | ||
| Admin string `json:"admin"` | ||
|
|
||
d34dh0r53 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| // +kubebuilder:validation:Optional | ||
| // +kubebuilder:default="KeystoneOIDCClientSecret" | ||
| // OIDCClientSecret - Selector to get the IdP client secret from the Secret | ||
| KeystoneOIDCClientSecret string `json:"keystoneOIDCClientSecret"` | ||
|
|
||
| // +kubebuilder:validation:Optional | ||
| // +kubebuilder:default="KeystoneOIDCCryptoPassphrase" | ||
| // OIDCCryptoPassphrase - Selector to get the OIDC crypto passphrase from the Secret | ||
| KeystoneOIDCCryptoPassphrase string `json:"keystoneOIDCCryptoPassphrase"` | ||
| } | ||
|
|
||
| // KeystoneFederationSpec to provide the configuration values for OIDC Federation | ||
| type KeystoneFederationSpec struct { | ||
| // +kubebuilder:validation:Optional | ||
| // +kubebuilder:default="OIDC-" | ||
| // OIDCClaimPrefix | ||
| OIDCClaimPrefix string `json:"oidcClaimPrefix"` | ||
|
|
||
| // +kubebuilder:validation:Optional | ||
| // +kubebuilder:default="id_token" | ||
| // OIDCResponseType | ||
| OIDCResponseType string `json:"oidcResponseType"` | ||
|
|
||
| // +kubebuilder:validation:Optional | ||
| // +kubebuilder:default="openid email profile" | ||
| // OIDCScope | ||
| OIDCScope string `json:"oidcScope"` | ||
|
|
||
| // +kubebuilder:validation:Optional | ||
| // +kubebuilder:default="" | ||
| // OIDCProviderMetadataURL | ||
| OIDCProviderMetadataURL string `json:"oidcProviderMetadataURL"` | ||
|
|
||
| // +kubebuilder:validation:Optional | ||
| // +kubebuilder:default="" | ||
| // OIDCIntrospectionEndpoint | ||
| OIDCIntrospectionEndpoint string `json:"oidcIntrospectionEndpoint"` | ||
|
|
||
| // +kubebuilder:validation:Optional | ||
| // +kubebuilder:default="" | ||
| // OIDCClientID | ||
| OIDCClientID string `json:"oidcClientID"` | ||
|
|
||
| // +kubebuilder:validation:Optional | ||
| // +kubebuilder:default=";" | ||
| // OIDCClaimDelimiter | ||
| OIDCClaimDelimiter string `json:"oidcClaimDelimiter"` | ||
|
|
||
| // +kubebuilder:validation:Optional | ||
| // +kubebuilder:default="claims" | ||
| // OIDCPassUserInfoAs | ||
| OIDCPassUserInfoAs string `json:"oidcPassUserInfoAs"` | ||
|
|
||
| // +kubebuilder:validation:Optional | ||
| // +kubebuilder:default="both" | ||
| // OIDCPassClaimsAs | ||
| OIDCPassClaimsAs string `json:"oidcPassClaimsAs"` | ||
|
|
||
| // +kubebuilder:validation:Optional | ||
| // +kubebuilder:default="memcache" | ||
| // OIDCCacheType | ||
| OIDCCacheType string `json:"oidcCacheType"` | ||
|
|
||
| // +kubebuilder:validation:Optional | ||
| // +kubebuilder:default="HTTP_OIDC_ISS" | ||
| // RemoteIDAttribute | ||
| RemoteIDAttribute string `json:"remoteIDAttribute"` | ||
|
|
||
| // +kubebuilder:validation:Optional | ||
| // +kubebuilder:default="" | ||
| // KeystoneFederationIdentityProviderName | ||
| KeystoneFederationIdentityProviderName string `json:"keystoneFederationIdentityProviderName"` | ||
| } | ||
|
Comment on lines
+219
to
279
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. we probably should think of a generic config customizion interface for httpd, like we have with customServiceConfig to not require most of these parameters. but right now we do not have it. |
||
|
|
||
| // HttpdCustomization - customize the httpd service | ||
|
|
@@ -233,7 +310,7 @@ type KeystoneAPIStatus struct { | |
| // TransportURLSecret - Secret containing RabbitMQ transportURL | ||
| TransportURLSecret string `json:"transportURLSecret,omitempty"` | ||
|
|
||
| //ObservedGeneration - the most recent generation observed for this service. If the observed generation is less than the spec generation, then the controller has not processed the latest changes. | ||
| // ObservedGeneration - the most recent generation observed for this service. If the observed generation is less than the spec generation, then the controller has not processed the latest changes. | ||
| ObservedGeneration int64 `json:"observedGeneration,omitempty"` | ||
| } | ||
|
|
||
|
|
||
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 |
|---|---|---|
| @@ -0,0 +1,43 @@ | ||
| apiVersion: keystone.openstack.org/v1beta1 | ||
| kind: KeystoneAPI | ||
| metadata: | ||
| name: keystone | ||
| spec: | ||
| adminProject: admin | ||
| adminUser: admin | ||
| customServiceConfig: | | ||
| [DEFAULT] | ||
| debug = true | ||
| databaseInstance: openstack | ||
| databaseAccount: keystone | ||
| preserveJobs: false | ||
| region: regionOne | ||
| secret: osp-secret | ||
| resources: | ||
| requests: | ||
| memory: "500Mi" | ||
| cpu: "1.0" | ||
| tls: | ||
| api: | ||
| # secret holding tls.crt and tls.key for the APIs internal k8s service | ||
| internal: | ||
| secretName: cert-keystone-internal-svc | ||
| # secret holding tls.crt and tls.key for the APIs public k8s service | ||
| public: | ||
| secretName: cert-keystone-public-svc | ||
| # secret holding the tls-ca-bundle.pem to be used as a deploymend env CA bundle | ||
| caBundleSecretName: combined-ca-bundle | ||
| oidcFederation: | ||
| keystoneFederationIdentityProviderName: my_federation_provider_name | ||
| oidcCacheType: memcache | ||
| oidcClaimDelimiter: ; | ||
| oidcClaimPrefix: OIDC- | ||
| oidcClientID: my_federation_client_id | ||
| oidcIntrospectionEndpoint: my_federation_introspection_endpoint | ||
| oidcMemCacheServers: "" | ||
| oidcPassClaimsAs: both | ||
| oidcPassUserInfoAs: claims | ||
| oidcProviderMetadataURL: my_federation_provider_metadata_url | ||
| oidcResponseType: id_token | ||
| oidcScope: openid email profile | ||
| remoteIDAttribute: HTTP_OIDC_ISS |
Uh oh!
There was an error while loading. Please reload this page.