50 Commits
Author SHA1 Message Date
Adam Reese 48d09a26d2 fix(pkg/plugin): copy plugins directly to the data directory (#7962)
Copy plugins from the cache rather than create a symlink.

fixes: #7206

Signed-off-by: Adam Reese <adam@reese.io>
(cherry picked from commit 1cdd0a2048)
2020-05-07 17:21:25 +00:00
ZouYu df9cf87cbe add unit test for function FindPlugins
Signed-off-by: ZouYu <zouy.fnst@cn.fujitsu.com>
2020-04-16 14:12:40 +08:00
Yaakov Selkowitz df20164cd2 Fix tests on arm64 and ppc64le (#7500)
Signed-off-by: Yaakov Selkowitz <yselkowi@redhat.com>
2020-01-31 09:59:35 +00:00
Vivian Kong 82823a6634 Allow tests to run on s390x (#7096)
Signed-off-by: Vivian Kong <vivkong@ca.ibm.com>
2020-01-17 15:39:26 +00:00
Josh Soref 02ad2b1187 Spelling (#7258)
* spelling: constraint

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: cryptographic

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: dependency

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: doesnot

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: don't

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: unexpected

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: dreadnought

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: default

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: envvars

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: evaluates

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: execute

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: extractor

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: frobnitz

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: generated

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: implementation

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: jabba

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: keywords

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: kubernetes

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: override

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: package

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: parsable

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: progress

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: recursively

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: release

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: cache

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: representing

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: serializer

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: subchart

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: utilities

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2019-12-18 12:04:08 +00:00
Taylor Thomas fca14bcb76 feat(plugin): Ports file mode preservation for tarballs from v3
This is a port of #5428 and readds a unit test for the `Extract` method

Signed-off-by: Taylor Thomas <taylor.thomas@microsoft.com>
2019-10-07 15:36:41 -06: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 d3805a1d54 ref(pkg/cli): refactor environment variable setup
This change sets proper defaults based on environment variables for
global settings and plugin environments.

Signed-off-by: Adam Reese <adam@reese.io>
2019-09-25 14:00:43 -07:00
Matt Farina 1ea53d8934 Unifity environment variable naming and use
Signed-off-by: Matt Farina <matt@mattfarina.com>
2019-09-04 14:15:30 -04:00
Adam Reese 1779ad5302 ref(cmd/helm): remove init command
Signed-off-by: Adam Reese <adam@reese.io>
2019-08-26 10:21:52 -07: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
Matthew Fisher 186f6c512f fix(plugin): add HELM_HOME back
This allows Helm 2 plugins that used HELM_HOME as a scratchpad to continue to work the same in Helm 3.

Signed-off-by: Matthew Fisher <matt.fisher@microsoft.com>
2019-08-02 13:42:21 -07:00
Matthew Fisher c728611e5a feat(cli): support XDG base directory specification
Signed-off-by: Matthew Fisher <matt.fisher@microsoft.com>
2019-08-02 13:15:03 -07:00
Oleg Sidorov ec440d446d Replaced ghodss/yaml with sigs.k8s.io/yaml
This commit replaces usage of github.com/ghodss/yaml with it's forked
version maintained by SIG community. The replaced library has
low-to-none support activity unlike the latter. We believe the new
Helm branch could benefit from using the community-supported version on
a long-term run as yaml parser is a key component of Helm chart rendering
engine.

This commit locks sigs.k8s.io/yaml dependency version on 1.1.0 which
is backwards compatible with ghodss/yaml 1.0.0.

This change also resolves the outdated dependency version lock for
ghodss/yaml (currently 1.0.0) and makes it possible to port changes from
https://github.com/helm/helm/pull/6010 to dev-v3.

Signed-off-by: Oleg Sidorov <oleg.sidorov@booking.com>
2019-07-12 16:52:15 +02:00
Matthew Fisher e410a03c74 ref(getter): introduce Options for passing in getter parameters
instead of hard-coding the parameters being passed in the constructor, we should pass in an Options struct that can be used to pass in those parameters.

Signed-off-by: Matthew Fisher <matt.fisher@microsoft.com>
2019-07-02 15:22:23 -07: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 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
Adam Reese 21d3a40f3b feat(tests): replace gometalinter with golangci-lint
Signed-off-by: Adam Reese <adam@reese.io>
2019-03-08 11:45:42 -08:00
Adam Reese f791421fab feat(Makefile): add formatting target
Signed-off-by: Adam Reese <adam@reese.io>
2019-02-08 12:24:47 -08:00
Martin Hickey 86d8596763 Feature(Plugins): Enable platform specific commands (#5176)
* Add logic for platform specific commands to plugins
* Add plugins doc updated to incorporate platform specific commands
* Add condition for os match:  If OS matches and there is no more specific match, the command
will be executed
2019-01-16 21:52:58 -08:00
Adam Reese 4f26b658d8 change copyright to "Copyright The Helm Authors" 2018-08-24 12:03:55 -07:00
Adam Reese 726e3c41be feat(*): print stacktrace on error with debug enabled 2018-05-10 09:34:41 -07:00
Adam Reese c50813af54 ref(*): remove local repository (dead code) 2018-04-25 09:35:29 -07:00
Adam Reese 19398a2ef1 feat(*): store release History in same namespace as release
https://github.com/kubernetes-helm/community/blob/master/helm-v3/003-state.md#namespacing-changes
2018-04-23 09:48:07 -07:00
Adam Reese 358746fee6 ref(*): remove HELM_HOST 2018-04-16 23:16:43 -07:00
Adam Reese 496ca54183 ref(*): bypass grpc for helm client 2018-04-16 11:19:22 -07:00
Adam Reese fa611fe285 fix(plugins): support installing plugins by relative path (#3568)
Support installing plugins by relative path

```
helm plugins install .
```
2018-02-26 15:49:07 -08:00
Adam Reese c314e2e2f1 fix(plugins): support newer git (#3571)
Newer gits don't like checking out an empty string.

```
empty string is not a valid pathspec. please use . instead if you meant to match all paths
```
2018-02-26 15:44:32 -08:00
oilbeater 0764d95a03 defer in loop may cause resource leak
defer statement executes only when function return, and the resource still be hold during loop. Release the resource manually when not needed.
2018-02-09 10:24:47 +08:00
Johan Lyheden 4831089500 Add tests to HTTPInstaller, update plugin documentation 2017-10-20 10:28:40 +02:00
Johan Lyheden f1a08adb41 Update to comply with linter rules and gofmt 2017-10-19 13:42:11 +02:00
Johan Lyheden d43d5ab452 Add plugin installer from http archive 2017-10-19 10:28:16 +02:00
Adam Reese a29e610938 fix(helm): fix flag parsing once and for all 2017-07-14 11:08:50 -07:00
Adam Reese 8272360681 Merge pull request #2476 from adamreese/fix/flag-envars
fix(helm): fix race conditions in flag parsing
2017-06-05 12:45:26 -07:00
Seth Goings e7a51d5424 fix(plugins): exists --> exist 2017-05-30 09:57:20 -06:00
Adam Reese d797acbd7b fix(helm): fix race conditions in flag parsing
* fix a number of issues with flag parsing
* add support for `HELM_DEBUG`
* lazy expand flag default envars
2017-05-29 17:58:27 -07:00
Sushil Kumar a6556b4982 Check existence of $HELM_HOME/plugins before installing plugin
Fixes https://github.com/kubernetes/helm/issues/2488
2017-05-25 15:04:10 -07:00
Adam Reese 1e8ebae249 fix(plugins): add error when updating modified plugins
If git has autosetuprebase enabled pulling will fail without a
descriptive error message.
2017-05-19 14:18:24 -07:00
Sushil Kumar ff42dadde4 Adds update option to plugin command (#2410)
* Adds update option to plugin command

Fixes issues/2385 - helm install silently updates the plugin, if it pre-existed

* Added tests for new methods for plugin update

* Updated docs

* Updated review comments :)

* Return error exit code when there is error
2017-05-16 11:07:15 -06:00
Sushil Kumar 24157e4aed Updated review comments :) 2017-05-06 15:59:20 -07:00
Sushil Kumar c84fb11a68 Errors out in case requested plugin exists
Partially fixes issues/2385 - helm install silently updates the plugin, if it pre-existed
2017-05-06 15:47:21 -07:00
Sushil Kumar 6344f1d8e9 Errors out in case requested plugin version does not exists
Fixes issues/2384 - helm plugin install installs a default version in case requested version is not available
2017-05-06 15:47:21 -07:00
Adam Reese 50eee83646 ref(helm): use new debug method to standardize debug output 2017-04-19 23:55:36 -07:00
Gergo Huszty b4ca198cc6 Pluggable downloaders. Closes #2093, #2094.
It is now possible to create plugins with chart download capabilities for custom, non-http protocols.
Furthermore it is possible to reuse helm packages to implement alternative clients with these custom downloader functions.
2017-04-16 20:58:03 +02:00
Adam Reese e611936893 ref(plugin): cleanup unused functions 2017-04-07 00:11:23 -07:00
Adam Reese 51b8d8a6ee feat(helm): add plugin management commands
Add plugin management subcommands for installing and removing plugins
to `$HELM_HOST/plugins`.

Install accepts a vcs url or a local directory.

```
$ helm plugin install http://github.com/adamreese/helm-env
Installed plugin: env

$ helm plugin list
NAME    	VERSION	DESCRIPTION
env     	0.1.0  	Print out the helm environment.

$ helm plugin remove env
Removed plugin: env
```

closes #1977
2017-04-06 11:28:09 -07:00
libesz 41f7c97a48 Fixing plugin test
In the TestLoadDir test case, currently reflect.DeepEqual is expected to fail by error. Expected metadata is different than in the fixture yaml. Also, the type of the struct is mismatching in DeepEqual call (struct vs pointer to struct).
2017-03-12 14:26:59 +01:00
Matt Butcher fad755e7ae feat(helm): add plugin system backend
This adds a backend for a plugin system.

Closes #1572
2016-11-29 10:28:54 -07:00