jfrog / charts

JFrog official Helm Charts
https://jfrog.com/integration/helm-repository/
Apache License 2.0
248 stars 435 forks source link

Helm upgrade of Xray Artifactory 3.x results in pending-upgrade status #757

Closed erick-duran-tfs closed 4 years ago

erick-duran-tfs commented 4 years ago

Is this a request for help?: yes


Is this a BUG REPORT or FEATURE REQUEST? (choose one): bug (?)

Version of Helm and Kubernetes: Helm: 3.1.0 Kubernetes: 1.14.9 (EKS)

Which chart: Xray 3.0.26

What happened: Tried to make an upgrade from already running release of the Xray chart 3.0.26 (default values) due to small configuration change. Release resulted in pending-upgrade status, and therefore all the resources deleted. Had to delete the release and run an install again.

What you expected to happen: That the release updated without causing downtime. Are upgrades in this new version no longer supported?

How to reproduce it (as minimally and precisely as possible):

  1. Install Xray chart 3.x with the default values.
  2. Do any configuration change and try to run an upgrade, providing any necessary passwords (rabbitmq, postgres, join key, master key, etc.). Same or new chart version.

Example ouput:

Release "xray" has been upgraded. Happy Helming!
NAME: xray
LAST DEPLOYED: Fri Apr  3 16:32:56 2020
NAMESPACE: xray
STATUS: pending-upgrade
REVISION: 2
TEST SUITE: None
HOOKS:
MANIFEST:

Anything else we need to know: I tried with multiple kinds of changes (scaling up the server + rabbitmq replica count), changing the master key secret name (to an existing one), changing the JFrog URL, etc. Even running with the same values retrieved using helm get values xray > values.yml+ passwords resulted in termination of all our pods.

Thanks in advance

chukka commented 4 years ago

@erick-duran Can you please provide some more Info

  1. Does this happen only on 3.0.26 chart version (fresh helm install & upgrade on same chart version)?
  2. Also can you share the helm install and helm upgrade command you tried so that i can try and replicate?
chukka commented 4 years ago

@erick-duran Is this still an issue ? please try with latest xray chart and also provide required info (as stated above)

erick-duran-tfs commented 4 years ago

Hello @chukka, Yes. This is still an issue, I've just tested it with the latest chart version (3.2.4). I can share you my values:

rabbitmq-ha:
  replicaCount: 2
  rabbitmqMemoryHighWatermark: 1000MB
  resources:
    requests:
      memory: "512Mi"
      cpu: "500m"
    limits:
      memory: "1Gi"
      cpu: "1"

server:
  replicaCount: 3
  resources:
    requests:
      memory: "1Gi"
      cpu: "500m"
    limits:
      memory: "2Gi"
      cpu: "1"

analysis:
  resources:
    requests:
      memory: "1Gi"
      cpu: "500m"
    limits:
      memory: "2Gi"
      cpu: "1"

persist:
  resources:
    requests:
      memory: "1Gi"
      cpu: "500m"
    limits:
      memory: "2Gi"
      cpu: "1"

indexer:
  resources:
    requests:
      memory: "1Gi"
      cpu: "500m"
    limits:
      memory: "2Gi"
      cpu: "1"
  persistence:
    size: 100Gi

postgresql:
  enabled: false

database:
  secrets:
    user:
      name: psql-secret
      key: user
    password:
      name: psql-secret
      key: password
    url:
      name: psql-secret
      key: url

xray:
  masterKeySecretName: xray-master-key
  jfrogUrl: https://my-artifactory-url.com
  joinKeySecretName: artifactory-join-key

What I did:

  1. Install the chart
    helm install xray jfrog/xray -n xray3 -f values.yml --version 3.2.4
  2. Upgrade the chart (with exactly the same values, just to test)
    helm upgrade xray jfrog/xray -n xray3 -f values.yml --version 3.2.4

    This results in a "deployed" status, but all the resources are terminated:

    
    $ helm upgrade xray jfrog/xray -n xray3 -f values.yml --version 3.2.4
    Release "xray" has been upgraded. Happy Helming!
    NAME: xray
    LAST DEPLOYED: Tue Apr 21 17:44:50 2020
    NAMESPACE: xray3
    STATUS: deployed
    REVISION: 2
    TEST SUITE: None

$ kubectl get all NAME READY STATUS RESTARTS AGE pod/xray-rabbitmq-ha-0 0/1 Terminating 0 12m pod/xray-xray-server-0 5/5 Terminating 0 12m

wait for a minute

$ kubectl get all No resources found in xray3 namespace.



Also weird that I didn't get any output similar to other service upgrades/installations.

And sorry for the delay!
erick-duran-tfs commented 4 years ago

Any updates on this? The issue persists and we have to re-deploy every time we want to do a configuration change (causing downtime). Chart version 3.3.0.

erick-duran-tfs commented 4 years ago

This was fixed in the newest chart. I was able to perform an upgrade with no problems.