rancher / charts-build-scripts

Apache License 2.0
9 stars 32 forks source link

Update lifecycle status #144

Closed nicholasSUSE closed 1 month ago

nicholasSUSE commented 1 month ago

Issue:

https://github.com/rancher/ecm-distro-tools/issues/445

Solution:

Preparing charts-build-scripts command lifecycle-status to be migrated into automation inside: ecm-distro-tools

Changing main behavior of lifecycle-status from creating and cloning a temporary directory structure for rancher/charts repository to executing all actions in the current charts repository and persisting the results to parsable state.json file that can be loaded by different commands.

Result example:

{
  "state_file": "/home/nick/WORK/SOFTWARE/go/src/github.com/release-work/charts/state.json",
  "in_lifecycle_current_branch": {
    "elemental": [
      {
        "Version": "104.1.1+up1.5.4"
      },
      {
        "Version": "104.1.0+up1.5.3"
      }
    ],
    "elemental-crd": [
      {
        "Version": "104.1.1+up1.5.4"
      },
      {
        "Version": "104.1.0+up1.5.3"
      }
    ]
  },
  "out_lifecycle_current_branch": {
    "prometheus-federator": [
      {
        "Version": "3.0.0+up0.3.3"
      },
      {
        "Version": "2.1.0+up0.3.0"
      }
    ]
  },
  "released_in_lifecycle": {
    "elemental": [
      {
        "Version": "104.1.1+up1.5.4"
      },
      {
        "Version": "104.1.0+up1.5.3"
      }
    ],
    "elemental-crd": [
      {
        "Version": "104.1.1+up1.5.4"
      },
      {
        "Version": "104.1.0+up1.5.3"
      }
    ]
  },
  "not_released_out_lifecycle": {
    "fleet": [
      {
        "Version": "100.2.3+up0.5.3"
      },
      {
        "Version": "100.2.0+up0.5.1"
      },
      {
        "Version": "100.1.1+up0.4.1"
      },
      {
        "Version": "100.1.0+up0.4.0"
      }
    ]
  },
  "not_released_in_lifecycle": {},
  "released_out_lifecycle": {
    "rancher-backup": [
      {
        "Version": "3.0.0"
      },
      {
        "Version": "2.1.5"
      },
      {
        "Version": "2.1.4"
      }
    ]
  },
  "to_be_released": {},
  "to_be_forward_ported": {}
}
nicholasSUSE commented 1 month ago

@briandowns all fixes implemented.