Skip to content

[mongodb] Wrong custom ca certs in new helm chart version #6697

Description

@epoddubny

Which chart:
mongodb-10.20.0

Describe the bug
After update to mongodb-10.20.0 from mongodb-10.19.0 custom CA certificates have been replaced.
In screenshots you can see that size of certificates are different in v10.19.0 and v10.20.0.


To Reproduce
Steps to reproduce the behavior:

  1. add custom certificates to values.yml
tls:
  enabled: true
  caCert: ${CA_CERT}
  caKey: ${CA_KEY}
  image:
    registry: docker.io
    repository: bitnami/nginx
    tag: 1.19.5-debian-10-r19
    pullPolicy: IfNotPresent
  1. deploy mongo with helm mongodb-10.19.0
String helmCommand = helmVersion == 3 ? 'helm3' : 'helm'    
invoke(kubeConfigVault) {        
  sh "${helmCommand} repo add bitnami https://charts.bitnami.com/bitnami"        
  sh "${helmCommand} repo update"        
  sh """${helmCommand} upgrade -i --wait \                
              ${helmVersion == 3 ? '--create-namespace' : ''} \                
              --namespace ${namespace} ${chartVersion ? '--version=' + chartVersion : ''} \                
              --set tls.enabled=true \                
              --set tls.caCert=${cacert} \                
              --set tls.caKey=${cakey} \                
              -f ${mongoValuesPath} \                
              ${releaseName} bitnami/mongodb"""    
}
  1. repeat step 2 for mongodb-10.20.0
  2. go to mongodb-ca secret and compare certificates

Expected behavior
A clear and concise description of what you expected to happen.

expect the same ca certs

Version of Helm and Kubernetes:

  • Output of helm version:
version.BuildInfo{Version:"v3.6.0", GitCommit:"7f2df6467771a75f5646b7f12afb408590ed1755", GitTreeState:"dirty", GoVersion:"go1.16.4"}
  • Output of kubectl version:
Client Version: version.Info{Major:"1", Minor:"21", GitVersion:"v1.21.1", GitCommit:"5e58841cce77d4bc13713ad2b91fa0d961e69192", GitTreeState:"clean", BuildDate:"2021-05-12T14:11:29Z", GoVersion:"go1.16.3", Compiler:"gc", Platform:"darwin/amd64"}
Server Version: version.Info{Major:"1", Minor:"19", GitVersion:"v1.19.10", GitCommit:"0000000000000000000000000000000000000000", GitTreeState:"archive", BuildDate:"2021-05-07T15:36:27Z", GoVersion:"go1.15.3", Compiler:"gc", Platform:"linux/amd64"}
WARNING: version difference between client (1.21) and server (1.19) exceeds the supported minor version skew of +/-1

Additional context
Add any other context about the problem here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions