kube_cluster 1.9.0 → 1.9.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2597321a575128ac29f8ef080595e150dab2d37bdf55562d75de3c252ab785a3
4
- data.tar.gz: 2513bd35ac124e04f574f3ecab461288c6989a474a48dbe517962f8e26a35275
3
+ metadata.gz: dc3333af0a836b40f716c65425aa368e06fedcf44bd7f928acaf6273cec97ecb
4
+ data.tar.gz: e7f8812a62a326590340348e0c267286ca6af89a269f4adb609aa901a6db8943
5
5
  SHA512:
6
- metadata.gz: 6ff84fb925d204f79a3bda56f5831df808e67d477b25f98d2cace2e9bee9dc868246ac613e98c9b8dca976bd6b31a80618b1da89bd52b40f8fccd0ee842d55a8
7
- data.tar.gz: a937837dce0b8ca84e5f3a092adeee6388239cfeccf4f767f2dc2b1f57c402bf388f1a1c6efbfa40817d1ec75ebb5246d921a97b3e871b3822e52a1b34d0a8d1
6
+ metadata.gz: 9b53f24653cdbea9b4f8b42e364e81ec63143a6dad262749f2b9aff5b339b559e54f9865cf61db7ba82bbe6f4166055e8d10edb957f7ee9fe25fd0b863a91a4d
7
+ data.tar.gz: c1bd574587131080153ae331e8800cc1afbfb240b1ba554994cc25dec26f651911f7c46edbe7e1b791172d0914193b57d65f54fdbfa02ac925b38218b9972b1d
data/CHANGELOG.md CHANGED
@@ -5,6 +5,15 @@ All notable changes to this project are documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [1.9.1] - 2026-09-28
9
+
10
+ ### Fixed
11
+ - `Chart#crds` no longer drops every CRD but the last for a chart shipping
12
+ several. `helm show crds` concatenates `crds/*.yaml` with no `---` between
13
+ them, so the stream parsed as a single document with duplicate top-level
14
+ keys. external-dns 1.22.0 hit this: `dnsendpoints` vanished and only
15
+ `dnsrecords` registered.
16
+
8
17
  ## [1.9.0] - 2026-09-28
9
18
 
10
19
  ### Added
data/flake.lock CHANGED
@@ -8,11 +8,11 @@
8
8
  "systems": "systems"
9
9
  },
10
10
  "locked": {
11
- "lastModified": 1790556091,
12
- "narHash": "sha256-+kgvg6vuaxjEUUad6pL+pxa3LZFveq3XvWGSZ+Z9gOA=",
11
+ "lastModified": 1790610895,
12
+ "narHash": "sha256-sansiZlrb60MrGFzTXNCVVMTU5EsGM6KWvZkA/aNp14=",
13
13
  "owner": "n-at-han-k",
14
14
  "repo": "flake.nix",
15
- "rev": "d023f40398596a5d80bf03e429c678a99b3f259a",
15
+ "rev": "0f3388742debac3e78751796f4568f441c0dee57",
16
16
  "type": "github"
17
17
  },
18
18
  "original": {
data/flake.nix CHANGED
@@ -10,11 +10,17 @@
10
10
  outputs = { self, nixpkgs, utils, mine }:
11
11
  utils.lib.eachDefaultSystem (system:
12
12
  let
13
- # No mine.overlays.default: it overrides pkg-config, which stdenv
14
- # splices, so the overlay rebuilds stdenv and all of nixpkgs from
15
- # source. mine.inputs.nixpkgs.follows makes it redundant anyway.
13
+ # No mine.overlays.default: it used to override pkg-config, which stdenv
14
+ # splices, so the overlay rebuilt stdenv and all of nixpkgs from source.
15
+ # mine.inputs.nixpkgs.follows makes it redundant anyway.
16
16
  pkgs = nixpkgs.legacyPackages.${system};
17
- ruby = pkgs.ruby_3_4;
17
+ lib = mine.lib.${system};
18
+
19
+ gems = lib.buildGemset {
20
+ name = "kube_cluster";
21
+ src = ./.;
22
+ };
23
+
18
24
  kubectlWithKubeconfig = pkgs.writeShellScriptBin "kubectl" ''
19
25
  #!${pkgs.bash}/bin/bash
20
26
  KUBECONFIG="$PWD/kubeconfig.yaml" ${pkgs.kubectl}/bin/kubectl "$@"
@@ -23,20 +29,15 @@
23
29
  {
24
30
  # pkg-config, bundix, libyaml, openssl, overmind, tmux and `bundix -l`
25
31
  # come from mkRubyShell.
26
- devShells.default = mine.lib.${system}.mkRubyShell {
32
+ devShells.default = lib.mkRubyShell {
27
33
  buildInputs = [
34
+ gems
35
+ gems.wrappedRuby
28
36
  pkgs.trufflehog
29
- ruby
30
37
  kubectlWithKubeconfig
31
38
  ];
32
39
 
33
40
  shellHook = ''
34
- export GEM_HOME="$HOME/.gem-${ruby.version}"
35
- export GEM_PATH="$GEM_HOME"
36
- export PATH="$GEM_HOME/bin:$PATH"
37
- export BUNDLE_PATH="$GEM_HOME"
38
- export BUNDLE_GEMFILE="$PWD/Gemfile"
39
- export BUNDLE_BIN="$GEM_HOME/bin"
40
41
  export KUBECONFIG="$PWD/kubeconfig.yaml"
41
42
  '';
42
43
  };
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Kube
4
4
  module Cluster
5
- VERSION = "1.9.0"
5
+ VERSION = "1.9.1"
6
6
  end
7
7
  end
@@ -161,12 +161,23 @@ module Kube
161
161
  def parse_crds(yaml_output)
162
162
  return [] if yaml_output.nil? || yaml_output.strip.empty?
163
163
 
164
- docs = YAML.safe_load_stream(yaml_output, permitted_classes: [Symbol])
164
+ docs = YAML.safe_load_stream(split_documents(yaml_output), permitted_classes: [Symbol])
165
165
  docs.compact
166
166
  .select { |doc| doc.is_a?(Hash) && doc["kind"] == "CustomResourceDefinition" }
167
167
  .map { |doc| Kube::Cluster["CustomResourceDefinition"].new(doc) }
168
168
  end
169
169
 
170
+ # `helm show crds` concatenates the chart's crds/*.yaml WITHOUT a `---`
171
+ # between them, so a chart shipping several CRDs arrives as one document
172
+ # with duplicate top-level keys -- and every CRD but the last is lost
173
+ # silently. external-dns 1.22.0 ships dnsendpoints and dnsrecords that
174
+ # way, and only dnsrecords survived. Start a document at every top-level
175
+ # `apiVersion:`; a file that already carries its own `---` yields an
176
+ # empty document, which the caller compacts away.
177
+ def split_documents(yaml_output)
178
+ yaml_output.gsub(/\n(?=apiVersion:)/, "\n---\n")
179
+ end
180
+
170
181
  # The chart source for helm commands — either a local path or a remote ref.
171
182
  def source
172
183
  @path || @ref
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kube_cluster
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.0
4
+ version: 1.9.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nathan K
8
8
  bindir: exe
9
9
  cert_chain: []
10
- date: 1980-01-01 00:00:00.000000000 Z
10
+ date: 1980-01-02 00:00:00.000000000 Z
11
11
  dependencies:
12
12
  - !ruby/object:Gem::Dependency
13
13
  name: rake