Skip to content
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

fix(crd): remove mentions of JMX in credential database #575

Merged
merged 1 commit into from
May 2, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions api/v1beta1/cryostat_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,9 @@ type CryostatSpec struct {
// +optional
// +operator-sdk:csv:customresourcedefinitions:type=spec
TargetDiscoveryOptions *TargetDiscoveryOptions `json:"targetDiscoveryOptions,omitempty"`
// Options to configure the Cryostat application's JMX credentials database.
// Options to configure the Cryostat application's credentials database.
// +optional
// +operator-sdk:csv:customresourcedefinitions:type=spec,displayName="JMX Credentials Database Options"
// +operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Credentials Database Options"
JmxCredentialsDatabaseOptions *JmxCredentialsDatabaseOptions `json:"jmxCredentialsDatabaseOptions,omitempty"`
}

Expand Down Expand Up @@ -522,9 +522,9 @@ type TargetDiscoveryOptions struct {
BuiltInDiscoveryDisabled bool `json:"builtInDiscoveryDisabled,omitempty"`
}

// JmxCredentialsDatabaseOptions provides configuration options to the Cryostat application's JMX credentials database.
// JmxCredentialsDatabaseOptions provides configuration options to the Cryostat application's credentials database.
type JmxCredentialsDatabaseOptions struct {
// Name of the secret containing the password to encrypt JMX credentials database.
// Name of the secret containing the password to encrypt credentials database.
// +optional
// +operator-sdk:csv:customresourcedefinitions:type=spec,xDescriptors={"urn:alm:descriptor:io.kubernetes:Secret"}
DatabaseSecretName *string `json:"databaseSecretName,omitempty"`
Expand Down
16 changes: 7 additions & 9 deletions bundle/manifests/cryostat-operator.clusterserviceversion.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ metadata:
capabilities: Seamless Upgrades
categories: Monitoring, Developer Tools
containerImage: quay.io/cryostat/cryostat-operator:2.4.0-dev
createdAt: "2023-05-01T14:54:37Z"
createdAt: "2023-05-02T15:53:41Z"
description: JVM monitoring and profiling tool
operatorframework.io/initialization-resource: |-
{
Expand Down Expand Up @@ -182,11 +182,10 @@ spec:
path: jmxCacheOptions.targetCacheTTL
x-descriptors:
- urn:alm:descriptor:com.tectonic.ui:number
- description: Options to configure the Cryostat application's JMX credentials
database.
displayName: JMX Credentials Database Options
- description: Options to configure the Cryostat application's credentials database.
displayName: Credentials Database Options
path: jmxCredentialsDatabaseOptions
- description: Name of the secret containing the password to encrypt JMX credentials
- description: Name of the secret containing the password to encrypt credentials
database.
displayName: Database Secret Name
path: jmxCredentialsDatabaseOptions.databaseSecretName
Expand Down Expand Up @@ -566,11 +565,10 @@ spec:
path: jmxCacheOptions.targetCacheTTL
x-descriptors:
- urn:alm:descriptor:com.tectonic.ui:number
- description: Options to configure the Cryostat application's JMX credentials
database.
displayName: JMX Credentials Database Options
- description: Options to configure the Cryostat application's credentials database.
displayName: Credentials Database Options
path: jmxCredentialsDatabaseOptions
- description: Name of the secret containing the password to encrypt JMX credentials
- description: Name of the secret containing the password to encrypt credentials
database.
displayName: Database Secret Name
path: jmxCredentialsDatabaseOptions.databaseSecretName
Expand Down
4 changes: 2 additions & 2 deletions bundle/manifests/operator.cryostat.io_clustercryostats.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -112,12 +112,12 @@ spec:
type: integer
type: object
jmxCredentialsDatabaseOptions:
description: Options to configure the Cryostat application's JMX credentials
description: Options to configure the Cryostat application's credentials
database.
properties:
databaseSecretName:
description: Name of the secret containing the password to encrypt
JMX credentials database.
credentials database.
type: string
type: object
maxWsConnections:
Expand Down
4 changes: 2 additions & 2 deletions bundle/manifests/operator.cryostat.io_cryostats.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -108,12 +108,12 @@ spec:
type: integer
type: object
jmxCredentialsDatabaseOptions:
description: Options to configure the Cryostat application's JMX credentials
description: Options to configure the Cryostat application's credentials
database.
properties:
databaseSecretName:
description: Name of the secret containing the password to encrypt
JMX credentials database.
credentials database.
type: string
type: object
maxWsConnections:
Expand Down
4 changes: 2 additions & 2 deletions config/crd/bases/operator.cryostat.io_clustercryostats.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -113,12 +113,12 @@ spec:
type: integer
type: object
jmxCredentialsDatabaseOptions:
description: Options to configure the Cryostat application's JMX credentials
description: Options to configure the Cryostat application's credentials
database.
properties:
databaseSecretName:
description: Name of the secret containing the password to encrypt
JMX credentials database.
credentials database.
type: string
type: object
maxWsConnections:
Expand Down
4 changes: 2 additions & 2 deletions config/crd/bases/operator.cryostat.io_cryostats.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -109,12 +109,12 @@ spec:
type: integer
type: object
jmxCredentialsDatabaseOptions:
description: Options to configure the Cryostat application's JMX credentials
description: Options to configure the Cryostat application's credentials
database.
properties:
databaseSecretName:
description: Name of the secret containing the password to encrypt
JMX credentials database.
credentials database.
type: string
type: object
maxWsConnections:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,11 +133,10 @@ spec:
path: jmxCacheOptions.targetCacheTTL
x-descriptors:
- urn:alm:descriptor:com.tectonic.ui:number
- description: Options to configure the Cryostat application's JMX credentials
database.
displayName: JMX Credentials Database Options
- description: Options to configure the Cryostat application's credentials database.
displayName: Credentials Database Options
path: jmxCredentialsDatabaseOptions
- description: Name of the secret containing the password to encrypt JMX credentials
- description: Name of the secret containing the password to encrypt credentials
database.
displayName: Database Secret Name
path: jmxCredentialsDatabaseOptions.databaseSecretName
Expand Down Expand Up @@ -505,11 +504,10 @@ spec:
path: jmxCacheOptions.targetCacheTTL
x-descriptors:
- urn:alm:descriptor:com.tectonic.ui:number
- description: Options to configure the Cryostat application's JMX credentials
database.
displayName: JMX Credentials Database Options
- description: Options to configure the Cryostat application's credentials database.
displayName: Credentials Database Options
path: jmxCredentialsDatabaseOptions
- description: Name of the secret containing the password to encrypt JMX credentials
- description: Name of the secret containing the password to encrypt credentials
database.
displayName: Database Secret Name
path: jmxCredentialsDatabaseOptions.databaseSecretName
Expand Down
4 changes: 2 additions & 2 deletions internal/controllers/secrets.go
Original file line number Diff line number Diff line change
Expand Up @@ -129,10 +129,10 @@ func (r *Reconciler) reconcileJMXSecret(ctx context.Context, cr *model.CryostatI
}

// databaseSecretNameSuffix is the suffix to be appended to the name of a
// Cryostat CR to name its JMX credentials database secret
// Cryostat CR to name its credentials database secret
const databaseSecretNameSuffix = "-jmx-credentials-db"

// dbSecretUserKey indexes the password within the Cryostat JMX credentials database Secret
// dbSecretUserKey indexes the password within the Cryostat credentials database Secret
const databaseSecretPassKey = "CRYOSTAT_JMX_CREDENTIALS_DB_PASSWORD"

func (r *Reconciler) reconcileDatabaseSecret(ctx context.Context, cr *model.CryostatInstance) error {
Expand Down