Commit graph

34 commits

Author SHA1 Message Date
Calvin Bui
b33d4ae0c0
Use length check for MetaDependencies instead of nil comparison
Signed-off-by: Calvin Bui <3604363+calvinbui@users.noreply.github.com>
2025-11-27 16:56:17 +11:00
tison
0d6de28bf4
chore: fix typo of public field
Signed-off-by: tison <wander4096@gmail.com>
2025-10-24 15:02:25 +08:00
Matt Farina
8dc7c57f50
Update the action interfaces for chart apiversions
This change is about handling the interfaces to public functions for
different chart apiVersions. The internals are still focused on v2.
This enables v3 to be layered in layer.

Signed-off-by: Matt Farina <matt.farina@suse.com>
2025-09-17 15:19:02 -04:00
Scott Rigby
e814ff3c38
Remove unnecessary file i/o operations from signing and verifying
Signed-off-by: Scott Rigby <scott@r6by.com>
2025-08-30 17:28:16 -05:00
Scott Rigby
9ea35da0d0
[HIP-0026] Plugin packaging, signing, and verification (#31176)
* Plugin packaging, signing and verification

Signed-off-by: Scott Rigby <scott@r6by.com>

* wrap keyring read error with more explicit message

Co-authored-by: Jesse Simpson <jesse.simpson36@gmail.com>
Signed-off-by: Scott Rigby <scott@r6by.com>

* skip unnecessary check

Co-authored-by: Evans Mungai <mbuevans@gmail.com>
Signed-off-by: Scott Rigby <scott@r6by.com>

* Change behavior for installing plugin with missing .prov file (now warns and continues instead of failing)

Signed-off-by: Scott Rigby <scott@r6by.com>

* Add comprehensive plugin verification tests

- Test missing .prov files (warns but continues)
- Test invalid .prov file formats (fails verification)
- Test hash mismatches in .prov files (fails verification)
- Test .prov file access errors (fails appropriately)
- Test directory plugins don't support verification
- Test installation without verification enabled (succeeds)
- Test with valid .prov files (fails on empty keyring as expected)

---------

Signed-off-by: Scott Rigby <scott@r6by.com>
Co-authored-by: Jesse Simpson <jesse.simpson36@gmail.com>
Co-authored-by: Evans Mungai <mbuevans@gmail.com>
2025-08-30 13:25:28 -04:00
Justen Stall
280a9ddbdb
Merge branch 'main' into stdlib-errors-2
Signed-off-by: Justen Stall <39888103+justenstall@users.noreply.github.com>
2025-04-21 12:13:10 -04:00
Krisztian Litkey
3102c28804
fix: allow signing multiple charts with passphrase from stdin.
Cache the signing key passphrase. When signing multiple charts
with the passphrase from stdin, this allows signing all charts
instead of all but the first failing with an error about stdin
already having been closed.

Signed-off-by: Krisztian Litkey <krisztian.litkey@intel.com>
2025-04-16 18:05:36 +03:00
Matt Farina
61d3eca55c
Move pkg/chart to pkg/chart/v2 to prepare for v3 charts
This change moves the code, updates the import locations, and
adds a doc.go file to document what the v2 package is for.

This is part of HIP 20 for v3 charts

Signed-off-by: Matt Farina <matt.farina@suse.com>
2025-02-25 15:20:44 -05:00
Matt Farina
5c0deec327
Moving chartutil to chart/util
chartutil was originally created to operate on protobufs which are
no longer part of Helm. The util package makes more sense to be
part of the chart package.

This change is part of the HIP 20 to create v3 charts and
explicitly call out v2 charts. The changes for this are in smaller
bite size changes.

Signed-off-by: Matt Farina <matt.farina@suse.com>
2025-02-21 15:25:55 -05:00
Matt Farina
2236294119 Updating to helm.sh/helm/v4
Since Helm is going through breaking changes with Helm v4, the version path to
Helm needs to be updated.

Signed-off-by: Matt Farina <matt.farina@suse.com>
2024-12-26 16:33:51 -05:00
Evans Mungai
7a22dd28d1
Rename CAFile to CaFile for consistency
Signed-off-by: Evans Mungai <mbuevans@gmail.com>
2024-11-19 21:18:27 +00:00
Justen Stall
63cf42a843
fix: replace "github.com/pkg/errors" with stdlib "errors" package
Signed-off-by: Justen Stall <39888103+justenstall@users.noreply.github.com>
2024-11-18 11:35:59 -05:00
Evans Mungai
12d8d28534
Add username/password to package subcommand
Signed-off-by: Evans Mungai <mbuevans@gmail.com>
2024-06-19 18:37:31 +01:00
Robert Sirchia
d58d7b3762 Fixing all the linting errors
Cleaned up all the linting errors we are getting.

Signed-off-by: Robert Sirchia <rsirchia@outlook.com>
2024-03-11 17:13:34 -04:00
Matt Farina
847369c184
Update to Go 1.21 for builds
Noteis:
1. This moves golangci scanning to a GitHub action. This will
   enable inline pointers to issues in the PR where linting fails.
2. Go 1.21 is specified in the go.mod because Kubernetes libs
   require it.
3. The lint issues were removed. Some were fixed while others
   were handled by skipping linting or using _ as an argument.
   Many of these can be refactored later for better cleanup.

Signed-off-by: Matt Farina <matt.farina@suse.com>
2024-01-08 15:48:36 -05:00
Matt Farina
4e7e939f19
Updating the Go version in go.mod
At this time both Go 1.19 and 1.20 are supported. The version
specified in the go.mod file is the minimum version we expect Helm
to be compiled against. This is the oldest supported version to
support environments where others compile Helm. The Helm project
is using Go 1.20 to build Helm itself.

Updating to Go 1.19 also includes dealing with io/ioutil
deprecation and some additional linting issues around staticcheck.
All the staticcheck issues were in test files so linting was
skipped for those.

Signed-off-by: Matt Farina <matt.farina@suse.com>
2023-03-22 11:52:30 -04:00
Josh Dolitsky
0b2fec08ac
Upgrade to oras v0.9.0 (#9269)
* Upgrade to oras v0.9.0

Signed-off-by: Josh Dolitsky <josh@dolit.ski>

* fix test-style

Signed-off-by: Josh Dolitsky <josh@dolit.ski>
2021-01-27 14:52:25 -05:00
wawa0210
2c19838295
Fix that the invalid version number of the helm package command will escape
Signed-off-by: wawa0210 <xiaozhang0210@hotmail.com>
2020-10-31 17:10:03 +08:00
Sebastian Sdorra
467bd49bb0
support passing signing passphrase from file or stdin (#8394)
Signed-off-by: Sebastian Sdorra <sebastian.sdorra@cloudogu.com>
2020-09-18 16:23:40 -06:00
Matt Farina
3fc88f2492
Fixing failing CI for windows
A fix introduced in #8631 caused a bug in Windows builds due to
a type difference between POSIX and Windows environments. This
change corrects that problem and provides a code comment to warn
others.

Signed-off-by: Matt Farina <matt@mattfarina.com>
2020-08-21 11:51:58 -04:00
Manuel Rüger
4abcdc40ef pkg/*: Small linting fixes
Signed-off-by: Manuel Rüger <manuel@rueg.eu>
2020-08-21 11:22:15 +02:00
Song Shukun
e9f40ed7a5 fix golint failure in pkg/action
Signed-off-by: Song Shukun <song.shukun@fujitsu.com>
2020-02-18 23:15:56 +09:00
Matthew Fisher
50dcd39ba5
fix(package): remove --set, --values, etc. flags
These flags snuck in through a feature that was reverted and removed in Helm 2, but snuck into Helm 3.

They were never hooked up or used, so they were a no-op. This shouldn't affect anyone.

Signed-off-by: Matthew Fisher <matt.fisher@microsoft.com>
2020-01-27 10:29:15 -08:00
Matt Farina
9bc7934f35
Updating the module for v3 as the major version
Signed-off-by: Matt Farina <matt@mattfarina.com>
2019-10-03 14:27:05 -04:00
Matt Farina
967f4fed42
Update dependencies
* Kubernetes updated to 1.16.1
* SemVer and Sprig updated to latest releases that leverage go
  modules
* Tests and checks updated. These already landed in v2 via PR 6457

Signed-off-by: Matt Farina <matt@mattfarina.com>
2019-10-03 13:49:07 -04:00
Adam Reese
b6fdd8783b
feat(cmd/helm): remove need for helm init command
* allow repository config via cli
* make `helm repo add` create repo config file if it does not exist
* squash a ton of bugs

Signed-off-by: Adam Reese <adam@reese.io>
2019-08-22 23:31:50 -07:00
Joe Lanford
68ee30b48c cmd/*,pkg/*: move ValueOptions to cmd package and decouple from SDK
Signed-off-by: Joe Lanford <joe.lanford@gmail.com>
2019-08-01 11:04:36 -04:00
Adam Reese
f1718462c9
Merge pull request #5761 from cpanato/GH-5741
fix missing package name
2019-05-22 13:48:36 -07:00
Adam Reese
b49db9e6e6
ref(pkg/chartutil): break up chartutil into logical files
Signed-off-by: Adam Reese <adam@reese.io>
2019-05-22 19:38:11 +02:00
Carlos Panato
b5f83a08e3
fix missing package name
Signed-off-by: Carlos Panato <ctadeu@gmail.com>
2019-05-19 23:09:45 +02:00
Adam Reese
295092cd7d
ref(pkg/action): refactoring dup code and linter fixes
Signed-off-by: Adam Reese <adam@reese.io>
2019-03-26 11:11:27 -07:00
Adam Reese
895e9192d4
feat(*): use vanity import helm.sh/helm
Signed-off-by: Adam Reese <adam@reese.io>
2019-03-13 13:43:47 -07:00
Matthew Fisher
f185103b60
ref(action): move AddFlags functions back to cmd
Signed-off-by: Matthew Fisher <matt.fisher@microsoft.com>
2019-03-13 08:58:35 -07:00
Matthew Fisher
2571dbf82f
ref: remove pkg/helm, pkg/hapi, pkg/tiller
Signed-off-by: Matthew Fisher <matt.fisher@microsoft.com>
2019-03-12 09:47:12 -07:00