Commit graph

146 commits

Author SHA1 Message Date
Taylor Thomas
0210d43a66
Merge pull request #6550 from thomastaylor312/fix/missing_debug
fix(cmd): Fix all the outputs
2019-10-07 14:03:11 -06:00
Taylor Thomas
3d64c6bb54 ref(cmd): Implement flag parsing for output format
Signed-off-by: Taylor Thomas <taylor.thomas@microsoft.com>
2019-10-07 12:58:36 -06:00
Taylor Thomas
768d27b387 ref(*): Refactors output into its own package
Signed-off-by: Taylor Thomas <taylor.thomas@microsoft.com>
2019-10-07 10:09:28 -06:00
Matthew Fisher
0ae0f0742d
fix(action): fix import statement
Signed-off-by: Matthew Fisher <matt.fisher@microsoft.com>
2019-10-05 11:51:10 -07:00
Matthew Fisher
02999565a4
Merge pull request #6556 from karuppiah7890/conditional-dependencies-not-working-v3
fix(pkg/action): fix conditional dependencies not working with reuse values
2019-10-05 11:00:28 -07:00
Matthew Fisher
c1e63a2a17
Merge pull request #6536 from karuppiah7890/fix-lint-for-no-package-found
fix silent lint ignore for non existing packaged charts
2019-10-05 10:57:26 -07:00
Karuppiah Natarajan
bb9426c4e2
fix(pkg/lint): fix lint silently ignoring non existing packaged charts
Closes #6428

Signed-off-by: Karuppiah Natarajan <karuppiah7890@gmail.com>
2019-10-04 21:28:16 +05:30
Taylor Thomas
3799d0024c fix(cmd): Fix all the outputs
There were two different methods and varying ways to output the status of a release.
This standardizes all of the outputs, but requires a breaking change. Output will
not perfectly match previous v3 output, and we had to break the printing function
in the `action` package, but now things are much more standardized.

Fixes #6238

Signed-off-by: Taylor Thomas <taylor.thomas@microsoft.com>
2019-10-03 17:03:19 -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
Matthew Fisher
c1fc24c84e
Merge pull request #6386 from VilledeMontreal/fix/testrunnocluster
Check connectivity to cluster for helm test run
2019-10-02 11:40:40 -07:00
Karuppiah Natarajan
337f52c566
fix(pkg/action): fix conditional dependencies not working with reuse values
Closes #6530

Signed-off-by: Karuppiah Natarajan <karuppiah7890@gmail.com>
2019-10-02 19:33:19 +05:30
Taylor Thomas
6ccb2897d9 PR fixes
Signed-off-by: Taylor Thomas <taylor.thomas@microsoft.com>
2019-10-01 13:38:57 -06:00
Taylor Thomas
36f3a4b326 fix(action): Protects against current resource conflicts
Currently, if using the --atomic flag or deleting a release that failed due to an already existing
resource, Helm will deleting those resources that aren't managed by it. This PR fixes the issue
by checking for pre-existing resources during install and upgrade. This is done as a validation
step so the release will not even be started if resources currently exist. This PR is inspired by
@xchapter7x's work in #3477.

This also fixes a small bug in upgrade where deletes fail if the resource was already deletes

Fixes #6407

Signed-off-by: Taylor Thomas <taylor.thomas@microsoft.com>
2019-09-30 16:11:40 -06:00
Martin Hickey
26dacf84aa
feat(cmd): Port child NOTES.txt rendering to Helm 3 (#6512)
* Port Helm 2 PR 4088 to Helm 3

Not a direct port as is but refactored for Helm 3.

Signed-off-by: Martin Hickey <martin.hickey@ie.ibm.com>

* Update unit test to test string retunred for different order

Signed-off-by: Martin Hickey <martin.hickey@ie.ibm.com>
2019-09-30 16:40:33 +01:00
Taylor Thomas
eac6a60001 feat(*): Ports all output functionality from v2
As part of this port, I removed some now superfluous code from the `action` package.
This is technically a breaking change, but since the package was introduced in v3, it
is highly unlikely anyone is using it and we are still within the beta window.

Also closes #6437

Signed-off-by: Taylor Thomas <taylor.thomas@microsoft.com>
2019-09-25 16:07:10 -06:00
Matthew Fisher
261e5b00ac
Merge pull request #6491 from bacongobbler/port-5700
fix(action): typo
2019-09-24 21:32:14 -07:00
Matthew Fisher
faa9048580
Merge pull request #6486 from bacongobbler/fix-6452
fix(action): invalidate discovery client cache on startup
2019-09-24 11:29:28 -07:00
Matthew Fisher
9742c8c5a2
fix(action): typo
Signed-off-by: Matthew Fisher <matt.fisher@microsoft.com>
2019-09-24 10:57:35 -07:00
Taylor Thomas
6419ff6961
Merge pull request #6480 from thomastaylor312/feat/cleanup_on_fail
feat(*): Ports `--cleanup-on-fail` to v3
2019-09-24 10:42:10 -06:00
Matthew Fisher
1b0b843d6a
fix(action): invalidate discovery client cache on startup
we want to force a cache invalidation to ensure that the Capabilities object always has the latest information from the server (Kubernetes server version, available API versions, etc). `kubectl version` forces a cache invalidation every time it's invoked, so this seems like a safe change that is identical to kubectl's behaviour.

Signed-off-by: Matthew Fisher <matt.fisher@microsoft.com>
2019-09-24 09:14:29 -07:00
Matthew Fisher
3e891dbde9
Merge pull request #6425 from AndiDog/helm-template-no-reachability-check
Fix reachability check which must be disabled for `helm template` (unless `--validate` is specified)
2019-09-24 08:36:53 -07:00
Taylor Thomas
17854e83af feat(*): Ports --cleanup-on-fail to v3
This ports the functionality of cleanup on fail to v3 as introduced in #4871. This has been tested manually
and would be a good candidate for a new acceptance test.

Signed-off-by: Taylor Thomas <taylor.thomas@microsoft.com>
2019-09-23 16:13:02 -06:00
Matthew Fisher
4971ed5077
fix(list): scrub list returned from .List()
This way only the latest release is displayed with `helm list`.

Signed-off-by: Matthew Fisher <matt.fisher@microsoft.com>
2019-09-23 15:00:16 -07:00
Andreas Sommer
3a843df1ff Fix reachability check which must be disabled for helm template (unless --validate is specified)
Signed-off-by: Andreas Sommer <andreas.sommer87@googlemail.com>
2019-09-16 13:13:05 +02:00
Karuppiah Natarajan
25324ca8db
fix install storing computed values in release instead of user supplied values
Signed-off-by: Karuppiah Natarajan <karuppiah7890@gmail.com>
2019-09-14 20:34:48 +05:30
Marc Khouzam
5aa7c20f7c Check connectivity to cluster for helm test run
Signed-off-by: Marc Khouzam <marc.khouzam@montreal.ca>
2019-09-07 15:15:24 -04:00
Taylor Thomas
01e562bd00
Merge pull request #6296 from andytom/fix/duplicate_error_msgs
Stop multiple error messages in lint results
2019-09-04 14:08:12 -06:00
Matt Butcher
0f332b67f1
fix: clear the discovery cache after CRDs are installed (#6332)
* fix: clear the discovery cache after CRDs are installed

This fixes an issue in which a chart could not contain both a CRD and an instance of that CRD. It works around a stale cache by force cache invalidation whenever a CRD is added.

Closes #6316

Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

* fix: wait for CRD to register before allowing CRDs to be installed

This fixes an issue with the previous version of this patch in which the CRD would not be available quickly enough.

Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

* feat: use Wait() to wait for CRDs to be ready

This forward-ports the CRD wait logic to Helm 3, and then uses that to wait for CRDs to be registered.

Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

* ref: moved the scheme modification to an appropriate place.

Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

* fix: turned warnings into fatal errors, fixed spelling, clear cache once

Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>
2019-09-04 08:32:24 -06:00
Matt Farina
01adf0d7a3
Merge pull request #6255 from waveywaves/fix/6237
(fix/issue-6237) Add check to see if connected to the kubernetes cluster
2019-09-04 09:17:23 -04:00
Marc Khouzam
f46df928cf fix(cmd/helm): Missing params for dir locations (#6300)
Signed-off-by: Marc Khouzam <marc.khouzam@ville.montreal.qc.ca>
2019-08-28 11:26:21 +01:00
Thomas O'Donnell
e5668f54fe Stop multiple error messages in lint results
Have fixed a minor error in the lint action that was causing Error
messages from linting chart getting added to the returned results
multiple times.

Signed-off-by: Thomas O'Donnell <andy.tom@gmail.com>
2019-08-27 19:22:23 +02:00
Vibhav Bobade
d00e328020 Applied check to actions
Signed-off-by: Vibhav Bobade <vibhav.bobde@gmail.com>
2019-08-27 04:16:02 +05:30
Adam Reese
f76b5f21ad
Merge pull request #6272 from adamreese/feat/initless
feat(cmd/helm): remove need for helm init command
2019-08-26 10:26:11 -07: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
Josh Dolitsky
af06037d23
chore(registry): upgrade to oras v0.7.0 (#6285)
Also:
* add --insecure flag to "registry login"
* fix bug parsing correct tag when port number present

Signed-off-by: Josh Dolitsky <jdolitsky@gmail.com>
2019-08-26 11:29:01 -05: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
Matt Farina
fba311ba23
Merge pull request #6243 from technosophos/feat/5871-crds-directory
feat: Add support for a crds/ directory
2019-08-20 11:38:28 -04:00
Taylor Thomas
7466c4ee3b
Merge pull request #6241 from waveywaves/fix/issue-6079
Clone the vals map for every path to avoid mutation
2019-08-20 09:31:34 -06:00
Vibhav Bobade
68a8f36a92 Fix Adding Errors from Linter.Messages to result.Errors
This also fixes <nil> beig added to result.Errors

Signed-off-by: Vibhav Bobade <vibhav.bobde@gmail.com>
2019-08-20 04:22:17 +05:30
Adam Reese
b2d5e41fc7
ref(*): remove dead code
Signed-off-by: Adam Reese <adam@reese.io>
2019-08-19 10:22:27 -07:00
Vibhav Bobade
9ab927f0bb Test for Linting multiple charts with the same vals instance
Signed-off-by: Vibhav Bobade <vibhav.bobde@gmail.com>
2019-08-19 04:25:14 +05:30
Vibhav Bobade
7da1f35386 Clone the vals map for every path to avoid mutation
Signed-off-by: Vibhav Bobade <vibhav.bobde@gmail.com>
2019-08-19 04:25:01 +05:30
Matt Butcher
98426d6ad3
feat: Add support for a crds/ directory
Closes #5871

Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>
2019-08-16 16:26:55 -06:00
Taylor Thomas
16544c8190 fix(registry): Updates registry to handle go 1.12.8 changes
Go 1.12.8 introduced some breaking fixes (see 3226f2d492)
for a CVE. This broke the way we were doing registry reference parsing.
This removes the call to the containerd libraries in favor of our own
parsing and adds additional unit tests

Signed-off-by: Taylor Thomas <taylor.thomas@microsoft.com>
2019-08-15 09:36:51 -06:00
Matthew Fisher
4c4b10668a
ref(test): join all hook manifests before building
Signed-off-by: Matthew Fisher <matt.fisher@microsoft.com>
2019-08-13 16:04:08 -07:00
Matthew Fisher
4d6d384741
style(action): fix style tests
Signed-off-by: Matthew Fisher <matt.fisher@microsoft.com>
2019-08-13 12:14:48 -07:00
Matthew Fisher
4c366c972d
fix(action): return an error if len > 0
Signed-off-by: Matthew Fisher <matt.fisher@microsoft.com>
2019-08-13 12:10:31 -07:00
Matthew Fisher
fddf066121
fix(test): restore --cleanup
Signed-off-by: Matthew Fisher <matt.fisher@microsoft.com>
2019-08-13 11:56:39 -07:00
Josh Dolitsky
6095070817
ref(internal/experimental/registry): pkg refactor (#6205)
No more magic separating the metadata from chart tarball - charts are
pushed to registry as a single tarball layer with Chart.yaml in tact.

No more fragile custom symlink chart storage, now following
the OCI Image Layout Specification for chart filesystem cache.

Also:
- Update to ORAS 0.6.0
- Simplify registry client setup with NewClientWithDefaults()
- Remove needless annotations and constants

Fixes #6068
Fixes #6141

Signed-off-by: Josh Dolitsky <jdolitsky@gmail.com>
2019-08-12 15:17:18 -05:00