Fixes issues/2398 - helm plugin remove does not works as expected
- [ ] plugin remove option is coded to remove multiple plugins, but instead returns error when more than one plugin is requested to be removed.
- [ ] plugin remove does not show any error/message for non-existent plugin.
Extracted delete specific code from ReleaseServer to external function
which is called from both Local and Remote ReleaseModules.
Made getVersionSet function from tiller package exported.
This change introduces the concept of Rudders - pluggable modules that
Tiller communicates with via grpc, which allow to decouple orchestration
logic from Tiller into separate service.
This commit consists of simple Rudder implementation which does exactly
the same thing as built in Tiller orchestrator - it creates all k8s
objects from provided manifest without orchestrating them.
--experimental-release flag is introduced to enable this behaviour.
This change allows to use the service and tiller outside of the cluster.
Following commits will add Rudder to helm deployment.
This flattens the getter package tree, adds tests, and changes a little
bit of the terminology to follow Go idioms. This also makes much of the
getter API private to begin with. This will give us more flexibility in
the future.
Updated the 'helm completion' command to take in the shell
as a parameter. Currently acceptable options are 'bash' and
'zsh'. Also fixed the completions to work with zsh in a manner
similar to what kubectl does.
Also updated the docs to reflect this change.
Closes#2201
This upgrades a warning to an error in cases where `requirements.yaml`
contains a requirement, but it's missing in charts/
This impacts install, upgrade, and package.
Closes#2209
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.
Fixes issues/2272
stable-repository-url is currently hard-coded for helm init,
so if a user wants to make a different intranet repository as stable repo,
only option left is to first do an init,
followed by repo delete and repo add.
A lot of community members are looking at `helm serve` as a production webserver to host their
charts. There are much better solutions out there like s3, wabs or gcs for cloud storage and
nginx, haproxy or apache for DIY dedicated web servers. Steering users in the right direction
will help users make the right decision when it comes to serving their charts in production.
Fixes https://github.com/kubernetes/helm/issues/2240
`helm install` command was calling chartutil.Load twice,
once from `run` method and
another time from `client.InstallRelease` which is called from `run` method in `cmd/helm/install.go`
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
This exposes the skip-refresh flag to helm init to make it possible to
initialize Helm without fetching the index.yaml of the stable repo.
This mirrors the behavior of 'helm dep up's skip-refresh flag.
Closes#2127
In order to allow the stream emitted by "helm init --debug" to be fed
back into "kubectl create/apply -f", use YAML starting and ending
document boundary markers instead of blank lines to separate the
individual manifests.
If a release's v1 config map was removed, 'helm upgrade' would fail. It
was calling the wrong function to get its history. This has been fixed.
Closes#1829
When downloader package moved to under /pkg, helmpath functions got called still from it, while it is under /cmd. This commit fixes the issue by moving helmpath after the downloader to have only cmd->pkg and pkg->pkg calls.
kubernetes has explicit delete message that user can know resources being deleted for sure,
suggest also add this behavior to helm, as it is too 'quiet' for deletion operation right now.
This makes it possible to do a `dep up` without refetching all of
the repositories.While it's less safe, it's useful when doing many
updates in a short period of time (such as in a CI/CD setting)
Closes#2019
This adds an environment variable, HELM_NO_PLUGINS, that can disable
the plugin system from loading plugins. It provides a general way for
turning the plugin system off.
Closes#1624
A regression was committed during 2.2.0 that broke the repositories.yaml
file format, switching the cache path from relative to absolute. This
fixes the error.
Closes#1974
The following commands:
helm dep update
helm dep build
are now able to take a requirements.yaml with dependency charts' repo defined as:
file://../local/path or file:///root/path
closes: #1884
When 'helm install', 'helm package', and 'helm upgrade' are run,
Helm will not issue any warnings if any dependencies listed in
a chart's requirements.yaml file are missing. This change includes
warnings when a chart is found in requirements.yaml but isn't
in charts/.
Closes#1567
I recently added a test to check the sorting of search results.
Unfortunately, the test didn't actually sort the results (_sigh_), so
it was failing occasionally on map ordering.
This adds the sort function that is supposed to be tested.
Closes#1925
Users can now specify a namespace filter for 'helm list'. Only the
releases within the specified namespace will be shown. For example,
'helm list --namespace foo' will only show releases for the 'foo'
namespace. Also added a namespace field to the table view.
Closes#1563
During search index construction, records were not correctly sorted by
version number, which resulted in the wrong records being inserted into
the index.
Along the way, added tests and fixed a few comments.
Closes#1897
A regression was introduced which required chart download URLs have the
same URL prefix as the chart repo that referenced them. A second
regression transformed that URL into a request for the latest version of
that chart, sidestepping semver constraints.
This fix closes both issues, which were present in the same function.
Closes#1845Closes#1846
* This is a simple mvp which processes a test definition with the
hook annotation for test when you run `helm test [release]`
* helm client cmd, proto def, tiller logic
When using pkg/helm as a third party client, I am using chartutil.LoadArchive()
to load a chart from an io.Reader. After that is loaded I wish to install/update that
chart, however InstallRelease and UpdateRelease only accepts a path rather than
something of type *chart.Chart. This adds a new function called InstallReleaseFromChart
which allows one to load a chart separate from the path, then install said chart.
Version cmd tries to set up a tunnel at RunE instead of using the
PersistentPreRunE. That means that for each version test (3) it
tries to set up the tunnel. When running the tests on an internetless
or whithout a valid k8s environment, the tunnel will fail with a
timeout of 20 seconds, meaning that it will take 60 seconds to
run the test.
This commit adds a fake tillerHost so it will not try to setup the
tunnel.
The --reset-values flag on upgrade instructs Tiller to reset the
upgraded release to the chart's built-in values.yaml, and ignore the
last install's overridden values.
Closes#1569
Installs, rollback, upgrade, and delete now accept a `--timeout` flag
that allows the user to specify the maximum number of seconds that
any kubernetes command can take.
Closes#1678
This verifies that by adding user information in the chart repo URL
via `helm repo add`, it will be attached to the request when downloading
the chart tarball and provenance file.
You can now specify the `-f` flag multiple times to include multiple
values files. The priority will be given to the last (right-most)
file specified.
Closes#1620
If a 'command:' is not found for a plugin, it will not result in an
ExitError, but in a PathError. This prevents that condition from
panicing.
Closes#1609
Previously, there was no way to get provenance data unless you were
verifying it. This allows `fetch` to get the provenance data, but not
perform any verification. Adding this will allow external plugins
to perform verification against other sources, like Keybase.
Normalize URLs before comparing them. This deviates slightly from the
URL spec, but in order to accomodate the predominant use pattern for
Helm. Specifically, './', '../', and '/' are all "interpreted" to be
filepath-like.
Closes#1588
This adds a hidden 'helm doc' command that generates documentation out
of the Helm help text.
Currently it can create:
- man pages for HELM(1)
- Markdown documentation
- bash autocompletions
Those are the three built-ins for Cobra.
The command is hidden so that it doesn't show up to the regular user,
since this is really a specialized task. It has the advantage of making
it trivially easy to install man pages and bash completion at installation time.
This fixes the port forward connection using helm on windows by assigning explicitely 'localhost' to 'TillerHost' in 'setupConnection'. Otherwise, the connection between the helm client with the Tiller server deployed on Kubernetes will not work.
This replaces the old set parser with a brand new one. This also changes
the internal algorithm from duplicating YAML to merging YAML, which
might solve a problem one user reported in chat, but which was never
captured in an issue.
Closes#1540Closes#1556
If gRPC fails to make a connection, the result is a log message and a
verbose error. This suppresses log output and replaces the error with a
much more succinct one.
Closes#1488
Two non-exported helper functions were added to the repo index test
file. They first try to link the file, since this is optimal. If the
link fails a copy occurs.
Fixes#1472
When 'helm serve' is run, this now generates an index.yaml file. Before,
that file was maintained externally, often manually.
Closes#793
Partially addresses #1404
This changes from --client-only and --server-only to --client and
--server. With this change, if no flags are specified, all info is
shown. If one flag is specified, only its info is shown.
This modifies 'helm version' to allow for local-only or server-only
versions to avoid cases where calling 'helm version' was resulting in
errors.
Closes#1440
Currently, --set simply appends data to the end of the existing values
YAML data. If a values file does not have a line feed at the end, the
set data is mis-appended. This fixes the issue by inserting a linefeed
between the --values data and --set data.
Closes#1430
This switches the local chart repo to use 127.0.0.1 instead of localhost
so that the net library does not negotiate localhost to an IPv6 address,
which is known to cause issues in some Docker containers.
Breaking Change: When testing on a system that does NOT have IPv4
configured, this will break 'helm serve'. We estimate this will impact
none of the current user base.
Closes#1410
This adds a --dry-run flag to init, and causes the manifest file for
Tiller to be emitted on --debug. Together, this means you can do a
'helm init --dry-run --debug' and dump the Tiller manifest much as you
can with 'helm install --dry-run --debug'.
This does not require a server round-trip.
Closes#1417
This prevents the index command from recursing through directories.
Behind the scenes, it swaps out the repository logic for the index file
logic.
Closes#1328
Between Alpha.4 and Alpha.5 there was a change in the indexing logic.
This prevent indices from being appended to (because those index files
were often broken). This change allows the user to explicitly merge an
existing index and a generated index.
Closes#1334
- decouple tunnel from kube client
- add context switching for init cmd
- add unit tests for installer and init command
- refactor installer and remove unused code
An release that does not contain chart metadata cannot print its chart
name/version. This fixes a bug found in the wild where a release did not
(for reasons yet unknown) contain a chart.
Closes#1348
This causes 'helm dep [up|install]' to ignore files in charts/ that
start with either a dot or an underscore. It also changes the
chartloader to ignore those files.
Also, if a 'helm dep up' does not find a charts/ directory, it creates
one.
Closes#1342
When a deletion fails to remove a manifest file, the release should
still be marked as deleted. This changes the error handling to try to
delete all manifests, and then mark the release as deleted, then return
the errors.
Closes#1305
I wrote urlJoin to fix URL joining, but I put it in the wrong place and
never used it. This moves it to the right place, and replaces the hacky
previous solution.
This removes the requirement that a fetch or install command must
explicitly state the version number to install. Instead, this goes to
the strategy used by OS package managers: Install the latest until told
to do otherwise.
Closes#1198
The original dependency resolution did not correctly resolve version or
URL of a dependency. Version was tracked by filename, and URL was
assumed to be absolute. This fixes both of those.
Closes#1277
This causes search to index by name/version instead of just name, which
means you can get a list of versions of a chart. The '--versions' flag
enables this behavior.
Partially fixes#1199
This performs a relatively weak in-memory translation of index file
data. It does not, in most cases, write the corrected data to disk, and
it emits a warning directly to STDERR each time it loads a deprecated
index.
Known limitations:
- It cannot recover certain bogus records that earlier alpha releases
generated (notably, where all chartfile data is missing)
- In some cases, it has to parse a filename to get version info. This is
lossy.
- Because it takes three passes through the YAML and JSON unmarshal, it
is not performant.
This feature is transitional and should be removed during the Beta
cycle, prior to the release of 2.0.0.
Closes#1265
When `helm install -f foo.yaml bar` is called, and then the release is
upgraded with `helm upgrade happy-panda bar`, this will now re-use the
values that were submitted with `-f foo.yaml`. The same is true for
values specified with `--set`.
Closes#1227
There was a bug in the repo tests that caused them to overwrite the
repositories.yaml file in that directory. Now, the entire tests (server
and client-side) run inside of a temp directory.
This implements a new index file format for repository indices. It also
implements a new format for requirements.yaml.
Breaking change: This will break all previous versions of Helm, and will
impact helm search, repo, serve, and fetch functions.
Closes#1197