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

feat: Make Cilium CLI work with Cilium installed through helm with a non-default name. #2430

Commits on Mar 26, 2024

  1. feat: Add customizable Helm release name for Cilium

    This update introduces a new parameter across several functions and actions to
    allow the user to specify a Helm release name for the Cilium installation.
    This enables referencing installations installed via Helm directly.
    The default Helm release name remains "cilium" when no custom release name is provided.
    
    Fixes: cilium#2274
    Signed-off-by: Matthew Hembree <47449406+matthewhembree@users.noreply.github.com>
    matthewhembree committed Mar 26, 2024
    Configuration menu
    Copy the full SHA
    4ec5d70 View commit details
    Browse the repository at this point in the history
  2. style: Improve log message formatting. Make consistent/conventional.

    In this update, several log messages in the sysdump.go file have been refactored
    to provide a clearer output. This was achieved by introducing colons for namespace
    detections and consistently formatting namespace outputs across messages.
    
    A small change radius was maintained for this commit. There were other log messages
    that could have been updated, but left in place.
    
    Signed-off-by: Matthew Hembree <47449406+matthewhembree@users.noreply.github.com>
    matthewhembree committed Mar 26, 2024
    Configuration menu
    Copy the full SHA
    e858b37 View commit details
    Browse the repository at this point in the history
  3. feat: Add helmReleaseName to hubble disable parameters.

    This is to allow `cilium hubble disable --helm-release-name foo` as missing
    from a previous/complimentary commit.
    
    Fixes: cilium#2274
    
    Signed-off-by: Matthew Hembree <47449406+matthewhembree@users.noreply.github.com>
    matthewhembree committed Mar 26, 2024
    Configuration menu
    Copy the full SHA
    0aead5c View commit details
    Browse the repository at this point in the history
  4. feat: Add helmReleaseName to Hubble uninstall pre-phase of the core u…

    …ninstall.
    
    This is to allow `cilium uninstall --helm-release-name foo` to correctly uninstall Hubble
    before uninstalling the core Cilium.
    
    This includes a fix to specify the namespace.
    
    Fixes: cilium#2274
    
    Signed-off-by: Matthew Hembree <47449406+matthewhembree@users.noreply.github.com>
    matthewhembree committed Mar 26, 2024
    Configuration menu
    Copy the full SHA
    d4d8808 View commit details
    Browse the repository at this point in the history
  5. fix: Add WaitDuration from defaults for hubble enable|disable for cil…

    …ium install|uninstall --wait.
    
    This is to correct a case where `cilium uninstall --wait` would be configured to wait for
    Hubble to uninstall(disable), but have an implied duration of 0. Causing a quasi-false
    error log message. The exit code is still 0, but it was misleading to see the error log
    in CI.
    
    Signed-off-by: Matthew Hembree <47449406+matthewhembree@users.noreply.github.com>
    matthewhembree committed Mar 26, 2024
    Configuration menu
    Copy the full SHA
    75f46d2 View commit details
    Browse the repository at this point in the history
  6. style: Reorganize parameters struct to enhance readability.

    The code in the install.go file has been rearranged. Helm properties such as
    'HelmRepository' and 'HelmReleaseName' have been moved to the top for better visibility,
    while 'ListVersions' and 'NodesWithoutCilium' have been moved to the bottom.
    The aim was to enhance code readability and organization.
    
    Signed-off-by: Matthew Hembree <47449406+matthewhembree@users.noreply.github.com>
    matthewhembree committed Mar 26, 2024
    Configuration menu
    Copy the full SHA
    b8b789a View commit details
    Browse the repository at this point in the history
  7. refactor: Move default Helm release name to sysdump package.

    The default Helm release name for Cilium, previously in "defaults
    .go", has been moved to "sysdump.go". This change was made to ensure
    that the default value is readily available in the same file where
    it's solely used. Now, the sysdump file locally hosts the
    private 'helmReleaseName' constant, which is directly assigned to
    'CiliumHelmReleaseName' (cilium sysdump --cilium-helm-release-name) if
    it's not set by the user.
    
    Signed-off-by: Matthew Hembree <47449406+matthewhembree@users.noreply.github.com>
    matthewhembree committed Mar 26, 2024
    Configuration menu
    Copy the full SHA
    23cd774 View commit details
    Browse the repository at this point in the history
  8. refactor: Remove unused constants in defaults.go.

    Removed unused Helm-related definitions in defaults.go file. Two
    constants, HelmValuesSecretKeyName and HelmChartVersionSecretKeyName,
    were unused and hence deleted.
    
    Signed-off-by: Matthew Hembree <47449406+matthewhembree@users.noreply.github.com>
    matthewhembree committed Mar 26, 2024
    Configuration menu
    Copy the full SHA
    b7f1c50 View commit details
    Browse the repository at this point in the history