profile
viewpoint
Matt Butcher technosophos @microsoft @azure Boulder, CO http://technosophos.com Creator of Helm, Glide, CNAB, Brigade, & PHP HTML5 parser. Authored "Go In Practice", "Illustrated Children's Guide to Kubernetes", and 7 other books. Ph.D.

helm/helm 17730

The Kubernetes Package Manager

Azure/draft 3928

A tool for developers to create cloud-native applications on Kubernetes.

brigadecore/brigade 1973

Event-based Scripting for Kubernetes.

helm/helm-classic 586

⚠️(OBSOLETE) Helm Classic v1

brigadecore/kashti 345

Kashti is a dashboard for your Brigade pipelines.

compose-spec/compose-spec 322

The Compose specification

michelleN/helm-tiller-rbac 60

Enable RBAC profiles for Tiller

Masterminds/vert 47

Command line version testing: Compare versions at the CLI for use in shell scripts and make files.

brigadecore/buck 34

Brigade Universal Controller for Kubernetes

brigadecore/brigade-k8s-gateway 23

Send Kubernetes events into a Brigade pipeline

issue commenthelm/helm

add --values and --set flag to helm package

The "wrappers" have a profound influence on some of the behaviors. Having switched parsers (and wrapper libraries) a few times early in the project, the core maintainers are keenly aware of the small discrepancies between them, an how those produce high-level compatibility issues.

There is a possibility that we might consider using a fork of ghodss/yaml IF AND ONLY IF the owners of that fork were committed to continued maintenance.

sslavic

comment created time in a day

pull request commenthelm/helm

WIP: Rewrite the renderResources function to make it usable

This is not done yet, and does not completely work. I will update when it is complete. In the meantime, you can reference this PR when other PRs try to change renderResources.

technosophos

comment created time in 4 days

PR opened helm/helm

WIP: Rewrite the renderResources function to make it usable

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

<!-- Thanks for sending a pull request! Here are some tips for you:

  1. Make sure to read the Contributing Guide before submitting your PR: https://github.com/helm/helm/blob/master/CONTRIBUTING.md
  2. If this PR closes another issue, add 'closes #<issue number>' somewhere in the PR summary. GitHub will automatically close that issue when this PR gets merged. Alternatively, adding 'refs #<issue number>' will not close the issue, but help provide the reviewer more context.-->

What this PR does / why we need it:

This refactors renderResource into a more sensible assembly of functions and structs

Special notes for your reviewer:

If applicable:

  • [ ] this PR contains documentation
  • [x] this PR contains unit tests
  • [x] this PR has been tested for backwards compatibility
+330 -12

0 comment

4 changed files

pr created time in 4 days

create barnchtechnosophos/k8s-helm

branch : ref/render-resources

created branch time in 4 days

pull request commenthelm/helm

[WIP] fix: send hook yaml into post-renderer (#7891)

A quick update: I am about 50% of the way through a refactor of renderResources.

kabakaev

comment created time in 4 days

issue commenthelm/community

get "from" chart version when upgrading

This issue should be filed in the helm/helm repo. https://github.com/helm/helm/issues

The present repository and issue queue are for issues of governance, architecture, and project management.

TangqiFeng

comment created time in 4 days

PR opened helm/community

Initial add of Helm CRD document

This is a draft of a document to provide a complete explanation of the CRD conundrum in Helm. The intention is to have one formal statement that we can direct others to so that they understand:

  • The nature of the problem
  • The reason for Helm's current implementation
  • The guidelines for future alternatives
  • The time frame for reconsidering our design choices

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

+324 -0

0 comment

1 changed file

pr created time in 4 days

create barnchtechnosophos/community

branch : doc/crds

created branch time in 4 days

issue openedsolo-io/wasm-image-spec

Media Types are inconsistent

Thanks for putting together this specification. It is clear and succinct. I am confused, though, about the exact media types.

The two defined MTs are:

application/vnd.io.wasm.module.config.v1+json
application/vnd.module.wasm.content.layer.v1+wasm

However, in the example, the Media Type used for config is different:

[
  {
    "mediaType": "application/vnd.module.wasm.config.v1+json",
    "digest": "sha256:d0a165298ae270c5644be8e9938036a3a7a5191f6be03286c40874d761c18abf",
    "size": 125,
    "annotations": {
      "org.opencontainers.image.title": "runtime-config.json"
    }
  },
  {
    "mediaType": "application/vnd.module.wasm.content.layer.v1+wasm",
    "digest": "sha256:5e82b945b59d03620fb360193753cbd08955e30a658dc51735a0fcbc2163d41c",
    "size": 1043056,
    "annotations": {
      "org.opencontainers.image.title": "filter.wasm"
    }
  }
]

Which one is correct? Or am I misunderstanding the text?

created time in 4 days

startedsolo-io/wasm-image-spec

started time in 4 days

Pull request review commenthelm/helm

fix: removed strict template errors from v2 linter

 import ( )  // Templates lints the templates in the Linter.-func Templates(linter *support.Linter, values []byte, namespace string, strict bool) {+func Templates(linter *support.Linter, values []byte, namespace string) {

I agree. It is okay to leave a no-op param in the name of preserving API compatibility.

jeff-knurek

comment created time in 6 days

issue commenthelm/helm

Unable to debug "lookup" function, as its disabled with `helm template`

I have specifically requested that our outside security auditing firm make some recommendations. I will update when we receive the results.

etsauer

comment created time in 8 days

PR opened helm/helm

fix test that modifies the wrong cache data

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

<!-- Thanks for sending a pull request! Here are some tips for you:

  1. Make sure to read the Contributing Guide before submitting your PR: https://github.com/helm/helm/blob/master/CONTRIBUTING.md
  2. If this PR closes another issue, add 'closes #<issue number>' somewhere in the PR summary. GitHub will automatically close that issue when this PR gets merged. Alternatively, adding 'refs #<issue number>' will not close the issue, but help provide the reviewer more context.-->

What this PR does / why we need it:

This fixes the bug where every time you run a test, it updates a timestamp in cmd/helm/testdata/helmhome/helm/repository/test-name-index.yaml

A recent fix to the search cache did indeed fix a bug, but also broke a unit test. The test was incorrectly pointing to the testdata from another test. As a result, the test was overwriting the wrong cache.

This is a simple fix that sets the correct cache data on the TestRepoAdd test.

Special notes for your reviewer:

If applicable:

  • [ ] this PR contains documentation
  • [X] this PR contains unit tests
  • [ ] this PR has been tested for backwards compatibility
+3 -2

0 comment

1 changed file

pr created time in 11 days

create barnchtechnosophos/k8s-helm

branch : fix/repo-add-test-use-cache

created branch time in 11 days

Pull request review commenthelm/helm

report name length errors in linter

 apiVersion: v1 entries: {}-generated: "2020-06-23T10:01:59.2530763-07:00"+generated: "2020-07-31T12:50:37.129802-06:00"

Fixed. I think I will go hunt down that test fixture error, too. Tests are not supposed to overwrite fixtures.

technosophos

comment created time in 11 days

push eventtechnosophos/k8s-helm

Matt Butcher

commit sha 2304704dc90d8c2ded373b62e01ee0229db3b6f7

fix name length check on lint Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

view details

push time in 11 days

push eventtechnosophos/k8s-helm

Matt Butcher

commit sha 568973393ac11aea9dbe3478eefb1a80a72a8ce4

fix name length check on lint Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

view details

push time in 11 days

Pull request review commenthelm/helm

report name length errors in linter

 apiVersion: v1 entries: {}-generated: "2020-06-23T10:01:59.2530763-07:00"+generated: "2020-07-31T12:50:37.129802-06:00"

That must be a new bug in that test. I will revert the file in this PR.

technosophos

comment created time in 11 days

push eventtechnosophos/k8s-helm

Matt Butcher

commit sha 38c2618116e99f0cbc5cc26af199c57609fbc650

report name length errors in linter Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

view details

push time in 11 days

PR opened helm/helm

report name length errors in linter

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

<!-- Thanks for sending a pull request! Here are some tips for you:

  1. Make sure to read the Contributing Guide before submitting your PR: https://github.com/helm/helm/blob/master/CONTRIBUTING.md
  2. If this PR closes another issue, add 'closes #<issue number>' somewhere in the PR summary. GitHub will automatically close that issue when this PR gets merged. Alternatively, adding 'refs #<issue number>' will not close the issue, but help provide the reviewer more context.-->

What this PR does / why we need it:

This is a bug fix.

When I rewrote linter for Helm 3.3, I missed the length check on resource names. This now produces an error if a name is longer than the prescribed 253 characters.

Special notes for your reviewer:

If applicable:

  • [ ] this PR contains documentation
  • [x] this PR contains unit tests
  • [x] this PR has been tested for backwards compatibility
+16 -2

0 comment

5 changed files

pr created time in 11 days

create barnchtechnosophos/k8s-helm

branch : fix/lint-for-name

created branch time in 11 days

issue commenthelm/helm

Upgrade fails but status is “deployed”?

@steinbachr the first command is run on --all-namespaces. Can you re-run it without that flag? If your default NS is not set to default, then the above would be expected behavior.

IdanAdar

comment created time in 14 days

pull request commenthelm/helm

Fix issue with install and upgrade running all hooks

I have started on a refactor of the renderResources function, but it is probably weeks out at least (given our PR velocity).

mattfarina

comment created time in 15 days

pull request commenthelm/helm

[WIP] fix: send hook yaml into post-renderer (#7891)

If you don't mind delaying for a few days, @kabakaev , I think that the real underlying problem is that the renderResources function is just doing too many things. I would like to look to see if there is a sensible way to refactor it that would make it much easier for changes like yours.

kabakaev

comment created time in 15 days

push eventtechnosophos/awesome-cold-showers

Matt Butcher

commit sha abfdddd4cc06149dc489d87c52021e65d69503ae

Add Go Concurrency paper by Tu, et al.

view details

Matt Butcher

commit sha ed38dcb0f7daae4afd5479aab41200839025915f

Updated the title, and added another caveat (per request)

view details

Hillel Wayne

commit sha e9584ec403d6652dafe82c637f99049fa37f1a91

Merge pull request #18 from technosophos/go-concurrency Add Go Concurrency paper by Tu, et al.

view details

Greg Gorlen

commit sha 85dc31a5f4ede6c2f4c90f51d3691af0251124e0

fix typo

view details

Hillel Wayne

commit sha 01c7f9c1ac567bf925ba5afc2dcf13de863850df

Merge pull request #24 from ggorlen/patch-1 fix typo

view details

Matt Butcher

commit sha f3f8cde3d1535355030aed60d27902689134164d

camelCase versus under_scores

view details

Matt Butcher

commit sha f24f53dd8e6495ae9dd915e0de009a360b956e6a

updated with suggestions from review

view details

push time in 15 days

PR opened hwayne/awesome-cold-showers

camelCase versus under_scores
  • [X] I have followed the code of conduct.
  • [X] I have followed the contributing guidelines and used the proper item format.
  • [X] This is not a duplicate.
  • [X] The resource is free.
  • [X] The resource is rigorous because: (please list) Two academic papers are cited, both published in respected journals.
  • [X] The resource is not obnoxious, condescending, etc.
  • [X] My writup is respectful of both sides.
  • [X] I've added reasonable caveats.
  • [X] I've noted if the resource is a video, pdf, etc.

This is what makes your repo fun: I was going to post the Binkley article, and then discovered the newer Sharif article and learned something new!

+19 -0

0 comment

1 changed file

pr created time in 18 days

push eventtechnosophos/awesome-cold-showers

Matt Butcher

commit sha 3d33c3051c4d4b5849559765f83a5017bbd89ba4

camelCase versus under_scores

view details

push time in 18 days

create barnchtechnosophos/awesome-cold-showers

branch : camel-case

created branch time in 18 days

pull request commenthwayne/awesome-cold-showers

Add Go Concurrency paper by Tu, et al.

I added your suggestion verbatim, as I liked the way you worded it.

technosophos

comment created time in 18 days

push eventtechnosophos/awesome-cold-showers

Matt Butcher

commit sha ed38dcb0f7daae4afd5479aab41200839025915f

Updated the title, and added another caveat (per request)

view details

push time in 18 days

pull request commenthwayne/awesome-cold-showers

Add Go Concurrency paper by Tu, et al.

Sure! So is the idea that the header is the title of the paper? I didn't pick up on that, but it totally makes sense.

technosophos

comment created time in 18 days

push eventtechnosophos/awesome-cold-showers

Matt Butcher

commit sha abfdddd4cc06149dc489d87c52021e65d69503ae

Add Go Concurrency paper by Tu, et al.

view details

push time in 18 days

PR opened hwayne/awesome-cold-showers

Add Go Concurrency paper by Tu, et al.
  • [X] I have followed the code of conduct.
  • [X] I have followed the contributing guidelines and used the proper item format.
  • [X] This is not a duplicate.
  • [X] The resource is free.
  • [X] The resource is rigorous because: (please list) It is an academic journal article published in ASPLOS 2019.
  • [X] The resource is not obnoxious, condescending, etc.
  • [X] My writup is respectful of both sides.
  • [X] I've added reasonable caveats.
  • [X] I've noted if the resource is a video, pdf, etc.
+10 -0

0 comment

1 changed file

pr created time in 18 days

create barnchtechnosophos/awesome-cold-showers

branch : go-concurrency

created branch time in 18 days

fork technosophos/awesome-cold-showers

For when people get too hyped up about things

fork in 18 days

pull request commentbrigadecore/brigade

Brigade 2.0 proposal for maintainer and community review

I just re-reviewed with the AMPQ 1 changes, and am good with the plan. Is there anything you want to add @lukepatrick?

krancour

comment created time in 20 days

Pull request review commenthelm/helm

Fix/8467 linter failing

 func Templates(linter *support.Linter, values map[string]interface{}, namespace 	} } +// validateTopIndentLevel checks that the content does not start with an indent level > 0.+//+// This error can occur when a template accidentally inserts space. It can cause+// unpredictable errors dependening on whether the text is normalized before being passed+// into the YAML parser. So we trap it here.+//+// See https://github.com/helm/helm/issues/8467+func validateTopIndentLevel(content string) error {+	// Read lines until we get to a non-empty one+	scanner := bufio.NewScanner(bytes.NewBufferString(content))+	for scanner.Scan() {+		line := scanner.Text()+		// If line is empty, skip+		if strings.TrimSpace(line) == "" {+			continue+		}+		// If it starts with one or more spaces, this is an error+		if strings.HasPrefix(line, " ") || strings.HasPrefix(line, "\t") {

Linter's job is mainly to be prescriptive. Indenting "at the top level" is a bad practice, so linter should warn about it.

technosophos

comment created time in 21 days

issue commenthelm/helm

[helm-3.3.0-rc.1] Helm Lint fails due to blank resource name

@mattfarina I created a PR here: #8496 But I don't know if this issue is considered blocking for 3.3. Feel free to set which release you want it on.

rblaine95

comment created time in 21 days

PR opened helm/helm

Fix/8467 linter failing

<!-- Thanks for sending a pull request! Here are some tips for you:

  1. Make sure to read the Contributing Guide before submitting your PR: https://github.com/helm/helm/blob/master/CONTRIBUTING.md
  2. If this PR closes another issue, add 'closes #<issue number>' somewhere in the PR summary. GitHub will automatically close that issue when this PR gets merged. Alternatively, adding 'refs #<issue number>' will not close the issue, but help provide the reviewer more context.-->

What this PR does / why we need it:

This PR addresses the problem identified in #8467. It adds a new linter rule that issues a warning when a YAML document starts out with extra spaces before the first YAML attribute.

For example, this YAML would produce a warning:

  apiVersion: v1
kind: Pod

It warns that there are extra spaces before apiVersion.

The reason for warning is that the YAML parser we use calibrates its spaces to the first line. Thus, it is a formatting error to start with spaces.

Special notes for your reviewer:

If applicable:

  • [ ] this PR contains documentation
  • [x] this PR contains unit tests
  • [x] this PR has been tested for backwards compatibility
+46 -0

0 comment

2 changed files

pr created time in 21 days

push eventtechnosophos/k8s-helm

Matt Butcher

commit sha 152115e2dd483bfeb36164f68a097d5f2536d65d

trap cases where the YAML indent is incorrect. Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

view details

push time in 21 days

issue commenthelm/helm

[helm-3.3.0-rc.1] Helm Lint fails due to blank resource name

Ah! Okay, I found the issue. The package k8s gets this YAML:

  apiVersion: v1
kind: Pod
metadata:
    name: foo

And parses it into this result:

rules.K8sYamlStruct{
  APIVersion:"v1", 
  Kind:"", 
  Metadata:rules.k8sYamlMetadata{
    Namespace:"",
    Name:"",
  }
}

So the parser figures out the indent depth by the first line, and seemingly ignores all content outdented from there. I think the linter is right to catch this case... but clearly we need a better error message.

It appears that in at least some parts of Helm, we to a strings.TrimWhitespace() on YAML docs prior to parsing, which we actually shouldn't do... but which in this case actually saves us from an error. I'm definitely not going to change any of those. But we might have other bugs in Helm related to this sort of thing.

rblaine95

comment created time in 22 days

issue commenthelm/helm

[helm-3.3.0-rc.1] Helm Lint fails due to blank resource name

I think I will try modifying the linter to provide an error when apiVersion is not found. That should definitely be the first thing that fails a lint, and I am not sure we check that

rblaine95

comment created time in 22 days

issue commenthelm/helm

[helm-3.3.0-rc.1] Helm Lint fails due to blank resource name

@rblaine95 If you feel comfortable compiling Helm, I built a version that will print out each template before it sends it into the linter. I'm using it now to try to reproduce what you are encountering. But you might be able to spot things faster on your end.

Here's the branch:

https://github.com/technosophos/k8s-helm/tree/fix/8467-linter-failing

I'll keep updating here if I find anything else new.

rblaine95

comment created time in 22 days

create barnchtechnosophos/k8s-helm

branch : fix/8467-linter-failing

created branch time in 22 days

issue commenthelm/helm

[helm-3.3.0-rc.1] Helm Lint fails due to blank resource name

Here's what it currently does:

  1. Check to see if the content is non-empty (after trimming whitespace)
  2. Parses it with a YAML parser, populating a very minimal struct
  3. Checks the struct for the name field
  4. Checks for deprecations
  5. Validates selectors on some types

So the template is non-empty, but the output is non-conformant. I am trying to reproduce given the info above. But without seeing what the problematic data is, it's hard to construct an exception or alternate handling.

rblaine95

comment created time in 22 days

issue commenthelm/helm

[helm-3.3.0-rc.1] Helm Lint fails due to blank resource name

Have you ran helm template on that segment above to see what it outputs? Lint's parsing is definitely more primitive than other areas of Helm. (It tends to not do any error correction so that it can find flaws). So it is possible that where Helm will normally ignore something, Lint might get snagged on it.

rblaine95

comment created time in 22 days

issue commenthelm/helm

[helm-3.3.0-rc.1] Helm Lint fails due to blank resource name

It may be possible that somehow an empty YAML document was being created, and the first lint rule to trigger was the name checker. An empty YAML document (e.g. between an --- or ===) will pass the parsing validation check, but would definitely fail every subsequent check.

rblaine95

comment created time in 25 days

pull request commenthelm/helm

Lockfiles without version ranges

Say a chart dependency references repo https://foo.example.com/stable. My understanding is that in the current code, it will add a repository named something like helm-manager-a576fe4.... So if a user does a helm repo list, they'll see a really weirdly named repo.

Could we go for a more clear name, like naming it foo.example.com/stable or foo-example-com-stable? That might make it a little easier on the user.

mattfarina

comment created time in a month

PR closed helm/community

Update Conferences section of Communication Page size/XS

This is the first PR I've opened here, but I saw a few links that seemed out of date and thought it would be an easy change.

Also, thanks for posting the Helm Summit talks so quickly!

+5 -3

3 comments

1 changed file

adzuci

pr closed time in a month

issue commenthelm/helm

add --values and --set flag to helm package

Switching that is a good idea -- but must be deferred to Helm 4. Someone should file a special issue for switching YAML parsers so we can track that for the Helm 4 process.

sslavic

comment created time in a month

issue commenthelm/helm

Dependencies: Resolve version when only URL is known

Again, I am going to be bitter and argue that my intention was that repos would always have to be added first. So I want to say that the current behavior is a bug. However, the people who created the feature did intend for the current case to work as it does. So, in good conscience we would have to call it a breaking change. I guess we could silently auto-add repos... maybe?

mattfarina

comment created time in a month

pull request commenthelm/helm

feat(helm): add recreate upgrade (rollback) strategy

The three of us you pinged are currently prioritizing other work over this particular feature addition. This PR is definitely difficult to review because it has the potential to break releases in unanticipated ways. I have become increasingly reluctant to introduce features in minor releases that have the potential to break things. Adam and I already did a deep review of the code, and I already left my own feeling that delete/recreate is a sufficient solution. While the trade-off there is possibly more downtime, it's a known trade-off without side-effects.

You'll have to get some of the other core maintainers to spend some time reviewing this if you really want it to get in.

dastrobu

comment created time in a month

issue commenthelm/helm

Dependencies: Resolve version when only URL is known

If we are talking about the lockfile, then I :100: agree. We should NEVER lock to a range, as that makes reproducible builds sketchy at best.

The issue above was one of the reasons why I argued for a long time that all repositories must have a named local repo cache. I did not like the implementation that was merged using URLs directly with no cache.

So this proposal is much closer to the way Helm was intended to work. I am okay with it, and would be even happier if these caches were not invisible. I don't see a reason to hide sources from users. (Other package managers don't do that, so I don't see why we should.)

The push-back I have heard that "helm shouldn't write cache data to the local filesystem" is a non-starter here. That's based on an exceedingly niche use case (CI in which no writable volumes are attached), and we should not design Helm around those cases to the detriment of the vast majority of our user population.

mattfarina

comment created time in a month

push eventhelm/helm

Matt Butcher

commit sha 2750e4d78181b614776d82031f6ddfece8d020e2

Lint dependencies (#7970) * feat: add dependency tests Signed-off-by: Matt Butcher <matt.butcher@microsoft.com> * replaced on-disk fixtures with in-memory fixtures Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

view details

push time in a month

delete branch technosophos/k8s-helm

delete branch : feat/7910-lint-dependencies-2

delete time in a month

PR merged helm/helm

Lint dependencies size/L

This adds linter rules for dependencies.

Closes #7910

+202 -12

5 comments

9 changed files

technosophos

pr closed time in a month

issue closedhelm/helm

Proposal: Add Linter rule for making sure subcharts have `dependencies` in Chart.yaml

This is a proposal to add a new linting rule to helm lint. This rule would warn the user on cases where a subchart exists in charts/ but is not declared in Chart.yaml.

Background:

In Helm 2, we added requirements.yaml after the major release, and thus had to keep things backward compatible until Helm 3. For that reason, it was possible to add a chart to the charts/ folder without adding it in requirements.yaml.

In Helm 3, we removed most of the backward compatibility code, making it required to add all subcharts to the dependencies section of Chart.yaml.

However, this was not enforced in code, and it is still possible to put subcharts into the chart without declaring them as dependencies, and get some of the desired behavior. While we should find and fix those cases, in the meantime we should add a linter rule warning that this is not expected behavior.

Proposed Rule:

The rule should check all of the charts in the charts/ directory and make sure they are present in the dependencies section of Chart.yaml.

closed time in a month

technosophos

Pull request review commentdeislabs/krustlet

Option to load modules from local filesystem

+//! `composite` implements building complex stores from simpler ones.++use crate::store::PullPolicy;+use crate::store::Store;+use async_trait::async_trait;+use oci_distribution::Reference;+use std::sync::Arc;++/// A `Store` that has additional logic to determine if it can satisfy+/// a particular reference. An `InterceptingStore` can be composed with+/// another Store to satisfy specific requests in a custom way.+pub trait InterceptingStore: Store {

To be honest, OCI registry is not an ideal storage format for WASM modules. And we've seen CapOne and Wasmer already introduce competing module distribution services. So there is a good chance that at some point in the not-too-distant future we are going to need to be able to fetch modules from other network-centric storage systems.

itowlson

comment created time in a month

push eventhelm/helm

zwwhdls

commit sha 0b31450452666da00e55c41699b5c320171e9748

[v2] fix stack overflow error in helm template. (#7185) * fix #6116 Signed-off-by: zwwhdls <zwwhdls@hotmail.com> * fix another extreme case Signed-off-by: zwwhdls <zwwhdls@hotmail.com>

view details

push time in a month

PR merged helm/helm

[v2] fix stack overflow error in helm template. blocked size/L v2.x

fix https://github.com/helm/helm/issues/6116

same as pr https://github.com/helm/helm/pull/7184

+114 -27

1 comment

2 changed files

zwwhdls

pr closed time in a month

pull request commentcncf/toc

Brigade 2020 Annual Review

Just checking in on this. We are unclear about the current policies, and are wondering if we need to go ping individual TOC members for a review, or if this entire process is no longer necessary with the new sandbox layout.

vdice

comment created time in a month

created tagcnabio/cnab-spec

tagcnab-security-1.0.0

Cloud Native Application Bundle Specification

created time in a month

delete branch technosophos/cnab-spec

delete branch : fix/typo-in-toc

delete time in a month

push eventcnabio/cnab-spec

Matt Butcher

commit sha b8e909bd14fb427cca78bd33d6b65ddca3fec1a1

Fixed a typo in the table of contents Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

view details

Matt Butcher

commit sha 450dd75e0e5d9b52f6775b9ee25c3b7450988301

Merge pull request #379 from technosophos/fix/typo-in-toc Fixed a typo in the table of contents

view details

push time in a month

PR merged cnabio/cnab-spec

Fixed a typo in the table of contents

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

+1 -1

1 comment

1 changed file

technosophos

pr closed time in a month

PR opened cnabio/cnab-spec

Fixed a typo in the table of contents

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

+1 -1

0 comment

1 changed file

pr created time in a month

create barnchtechnosophos/cnab-spec

branch : fix/typo-in-toc

created branch time in a month

pull request commentcnabio/cnab-spec

CNAB Security 1.0 GA

Chris and I both voted on this issue, but met today and re-confirmed that we believe the proposal is ready for release. Therefore, this proposal has been ratified.

radu-matei

comment created time in a month

pull request commentcncf/toc

Brigade 2020 Annual Review

What is the process with this PR going forward? Is it to be merged? We (the Brigade maintainers) are not sure what else we are supposed to do.

vdice

comment created time in a month

pull request commentcnabio/cnab-spec

CNAB Security 1.0 GA

Can someone put this on a branch that @chris-crone and I can vote on and tag? I think @vdice is the resident expert on this process.

radu-matei

comment created time in a month

pull request commenthelm/helm

fix(engine): clone Template for tpl

Can you give any indication of what the performance gain is?

diafour

comment created time in a month

pull request commenthelm/helm

Lint dependencies

I would like to hold it for 3.4. It is a little contentious, so I figure we let the other linter changes go through, then do this one separately. As soon as the 3.3 branch is cut, I can merge this.

technosophos

comment created time in 2 months

issue commentchartmuseum/helm-push

how to support more arch ,such as mips64le

Sorry... I am not a core maintainer on this project, so I don't know.

duchuanLX

comment created time in 2 months

issue commenthelm/helm

Exception thrown when nesting > 4 levels in command line values

Feel free to contribute a patch that traps the panic and returns a proper error. I don't think anyone is working on it.

v-lealli

comment created time in 2 months

issue commenthelm/helm

helm lint issue with umbrella chart having templates folder

I have already explained that it is DEFINITELY an issue involving tpl. To function in "proper isolation", tpl has to re-render the entire template tree on each invocation, creating a sandbox for each call. That is expensive. The bigger the chart, the more expensive the re-render is. And the more calls you make to tpl, the more frequently this re-render will be performed. tpl is simply incapable of scaling and should be avoided. It's basically the eval of Helm templates.

If someone wants to take another crack at implementing tpl while still maintaining the security model, I'm fine with that. But in lieu of that, the answer is simple: Don't use tpl. Use Helmfile or some other external tool for pregenerating, or ask in the Slack channel how other people did similar things.

himmakam

comment created time in 2 months

Pull request review commenthelm/helm-www

Adding documentation on template functions

+---+title: "Template Function List"+description: "A list of template functions available in Helm"+weight: 6+---++Helm includes many template functions you can take advantage of in templates. They are listed here and broken down by the following categories:++* [Cryptographic and Security](#cryptographic-and-security-functions)+* [Date](#date-functions)+* [Dictionaries](#dictionaries-and-dict-functions)+* [Encoding](#encoding-functions)+* [File Path](#file-path-functions)+* [Kubernetes and Chart](#kubernetes-and-chart-functions)+* [Logic and Flow Control](#logic-and-flow-control-functions)+* [Lists](#lists-and-list-functions)+* [Math](#math-functions)+* [Network](#network-functions)+* [Reflection](#reflection-functions)+* [Regular Expressions](#regular-expressions)+* [Semantic Versions](#semantic-version-functions)+* [String](#string-functions)+* [Type Conversion](#type-conversion-functions)+* [URL](#url-functions)+* [UUID](#uuid-functions)++## Logic and Flow Control Functions++Helm includes numerous logic and control flow functions including [and](#and), [coalesce](#coalesce), [default](#default), [empty](#empty), [eq](#eq), [fail](#fail), [ge](#ge), [gt](#gt), [le](#le), [lt](#lt), [ne](#ne), [not](#not), and [or](#or).++### and++Returns a boolean and of the two arguments.++```+and .Arg1 .Arg2+```++### or++Returns the boolean or of the two arguments. It returns the first non-empty argument or the last argument.++```+or .Arg1 .Arg2+```++### not++Returns the boolean negation of its argument.++```+not .Arg+```++### eq++Returns the boolean equality of the arguments (e.g., Arg1 == Arg2).++```+eq .Arg1 .Arg2+```++### ne++Returns the boolean inequality of the arguments (e.g., Arg1 != Arg2)++```+ne .Arg1 .Arg2+```++### lt++Returns a boolean true if the first argument is less than the second. False is returned otherwise (e.g., Arg1 < Arg2).++```+lt .Arg1 .Arg2+```++### le++Returns a boolean true if the first argument is less than or equal to the second. False is returned otherwise (e.g., Arg1 <= Arg2).++```+le .Arg1 .Arg2+```++### gt++Returns a boolean true if the first argument is greater than the second. False is returned otherwise (e.g., Arg1 > Arg2).++```+gt .Arg1 .Arg2+```++### ge++Returns a boolean true if the first argument is greater than or equal to the second. False is returned otherwise (e.g., Arg1 >= Arg2).++```+ge .Arg1 .Arg2+```++### default++To set a simple default value, use `default`:++```+default "foo" .Bar+```++In the above, if `.Bar` evaluates to a non-empty value, it will be used. But if+it is empty, `foo` will be returned instead.++The definition of "empty" depends on type:++- Numeric: 0+- String: ""+- Lists: `[]`+- Dicts: `{}`+- Boolean: `false`+- And always `nil` (aka null)++For structs, there is no definition of empty, so a struct will never return the+default.++### empty++The `empty` function returns `true` if the given value is considered empty, and+`false` otherwise. The empty values are listed in the `default` section.++```+empty .Foo+```++Note that in Go template conditionals, emptiness is calculated for you. Thus,+you rarely need `if empty .Foo`. Instead, just use `if .Foo`.++### fail++Unconditionally returns an empty `string` and an `error` with the specified+text. This is useful in scenarios where other conditionals have determined that+template rendering should fail.++```+fail "Please accept the end user license agreement"+```++### coalesce++The `coalesce` function takes a list of values and returns the first non-empty+one.++```+coalesce 0 1 2+```++The above returns `1`.++This function is useful for scanning through multiple variables or values:++```+coalesce .name .parent.name "Matt"+```++The above will first check to see if `.name` is empty. If it is not, it will return+that value. If it _is_ empty, `coalesce` will evaluate `.parent.name` for emptiness.+Finally, if both `.name` and `.parent.name` are empty, it will return `Matt`.++### ternary++The `ternary` function takes two values, and a test value. If the test value is+true, the first value will be returned. If the test value is empty, the second+value will be returned. This is similar to the c ternary operator.++#### true test value++```+ternary "foo" "bar" true+```++or++```+true | ternary "foo" "bar"+```++The above returns `"foo"`.++#### false test value++```+ternary "foo" "bar" false+```++or++```+false | ternary "foo" "bar"+```++The above returns `"bar"`.++## String Functions++Helm includes the following string functions: [abbrev](#abbrev), [abbrevboth](#abbrevboth), [camelcase](#camelcase), [cat](#cat), [contains](#contains), [hasPrefix](#hasprefix-and-hassuffix), [hasSuffix](#hasprefix-and-hassuffix), [indent](#indent), [initials](#initials), [kebabcase](#kebabcase), [lower](#lower), [nindent](#nindent), [nospace](#nospace), [plural](#plural), [print](#print), [printf](#printf), [println](#println), [quote](#quote-and-squote), [randAlpha](#randalphanum-randalpha-randnumeric-and-randascii), [randAlphaNum](#randalphanum-randalpha-randnumeric-and-randascii), [randAscii](#randalphanum-randalpha-randnumeric-and-randascii), [randNumeric](#randalphanum-randalpha-randnumeric-and-randascii), [repeat](#repeat), [replace](#replace), [shuffle](#shuffle), [snakecase](#snakecase), [squote](#quote-and-squote), [substr](#substr), [swapcase](#swapcase), [title](#title), [trim](#trim), [trimAll](#trimall), [trimPrefix](#trimprefix), [trimSuffix](#trimsuffix), [trunc](#trunc), [untitle](#untitle), [upper](#upper), [wrap](#wrap), and [wrapWith](#wrapwith).++### print++Returns a string from the combination of its parts.++```+print "Matt has " .Dogs " dogs"+```++Types that are not strings are converted to strings where possible.++Note, when two arguments next to each other are not strings a space is added between them.++### println++Works the same way as [print](#print) but adds a new line at the end.++### printf++Returns a string based on a formatting string and the arguments to pass to it in order.++```+printf "%s has %d dogs." .Name .NumberDogs+```++The placeholder to use depends on the type for the argument being passed in. This includes:++General purpose:++* `%v` the value in a default format+	when printing dicts, the plus flag (%+v) adds field names+* `%%` a literal percent sign; consumes no value++Boolean:++* `%t` the word true or false++Integer:++* `%b` base 2+* `%c` the character represented by the corresponding Unicode code point+* `%d` base 10+* `%o` base 8+* `%O` base 8 with 0o prefix+* `%q` a single-quoted character literal safely escaped+* `%x` base 16, with lower-case letters for a-f+* `%X` base 16, with upper-case letters for A-F+* `%U` Unicode format: U+1234; same as "U+%04X"++ Floating-point and complex constituents:++* `%b` decimalless scientific notation with exponent a power of two, e.g. -123456p-78+* `%e` scientific notation, e.g. -1.234456e+78+* `%E` scientific notation, e.g. -1.234456E+78+* `%f` decimal point but no exponent, e.g. 123.456+* `%F` synonym for %f+* `%g` %e for large exponents, %f otherwise.+* `%G` %E for large exponents, %F otherwise+* `%x` hexadecimal notation (with decimal power of two exponent), e.g. -0x1.23abcp+20+* `%X` upper-case hexadecimal notation, e.g. -0X1.23ABCP+20++String and slice of bytes (treated equivalently with these verbs):++* `%s` the uninterpreted bytes of the string or slice+* `%q` a double-quoted string safely escaped+* `%x` base 16, lower-case, two characters per byte+* `%X` base 16, upper-case, two characters per byte++Slice:++* `%p` address of 0th element in base 16 notation, with leading 0x++### trim++The `trim` function removes white space from both sides of a string:++```+trim "   hello    "+```++The above produces `hello`++### trimAll++Removes the given characters from the front and back of a string:++```+trimAll "$" "$5.00"+```++The above returns `5.00` (as a string).++### trimPrefix++Trim just the prefix from a string:++```+trimPrefix "-" "-hello"+```++The above returns `hello`++### trimSuffix++Trim just the suffix from a string:++```+trimSuffix "-" "hello-"+```++The above returns `hello`++### lower++Convert the entire string to lowercase:++```+lower "HELLO"+```++The above returns `hello`++### upper++Convert the entire string to uppercase:++```+upper "hello"+```++The above returns `HELLO`++### title++Convert to title case:++```+title "hello world"+```++The above returns `Hello World`++### untitle++Remove title casing. `untitle "Hello World"` produces `hello world`.++### repeat++Repeat a string multiple times:++```+repeat 3 "hello"+```++The above returns `hellohellohello`++### substr++Get a substring from a string. It takes three parameters:++- start (int)+- end (int)+- string (string)++```+substr 0 5 "hello world"+```++The above returns `hello`++### nospace++Remove all whitespace from a string.++```+nospace "hello w o r l d"+```++The above returns `helloworld`++### trunc++Truncate a string++```+trunc 5 "hello world"+```++The above produces `hello`.++```+trunc -5 "hello world"+```++The above produces `world`.++### abbrev++Truncate a string with ellipses (`...`)++Parameters:++- max length+- the string++```+abbrev 5 "hello world"+```++The above returns `he...`, since it counts the width of the ellipses against the maximum length.++### abbrevboth++Abbreviate both sides:++```+abbrevboth 5 10 "1234 5678 9123"+```++the above produces `...5678...`++It takes:++- left offset+- max length+- the string++### initials++Given multiple words, take the first letter of each word and combine.++```+initials "First Try"+```++The above returns `FT`++### randAlphaNum, randAlpha, randNumeric, and randAscii++These four functions generate cryptographically secure (uses ```crypto/rand```)+random strings, but with different base character sets:++- `randAlphaNum` uses `0-9a-zA-Z`+- `randAlpha` uses `a-zA-Z`+- `randNumeric` uses `0-9`+- `randAscii` uses all printable ASCII characters++Each of them takes one parameter: the integer length of the string.++```+randNumeric 3+```++The above will produce a random string with three digits.++### wrap++Wrap text at a given column count:++```+wrap 80 $someText+```++The above will wrap the string in `$someText` at 80 columns.++### wrapWith++`wrapWith` works as `wrap`, but lets you specify the string to wrap with.+(`wrap` uses `\n`)++```+wrapWith 5 "\t" "Hello World"+```++The above produces `hello world` (where the whitespace is an ASCII tab+character)++### contains++Test to see if one string is contained inside of another:++```+contains "cat" "catch"+```++The above returns `true` because `catch` contains `cat`.++### hasPrefix and hasSuffix++The `hasPrefix` and `hasSuffix` functions test whether a string has a given+prefix or suffix:++```+hasPrefix "cat" "catch"+```++The above returns `true` because `catch` has the prefix `cat`.++### quote and squote++These functions wrap a string in double quotes (`quote`) or single quotes+(`squote`).++### cat++The `cat` function concatenates multiple strings together into one, separating+them with spaces:++```+cat "hello" "beautiful" "world"+```++The above produces `hello beautiful world`++### indent++The `indent` function indents every line in a given string to the specified+indent width. This is useful when aligning multi-line strings:++```+indent 4 $lots_of_text+```++The above will indent every line of text by 4 space characters.++### nindent++The `nindent` function is the same as the indent function, but prepends a new+line to the beginning of the string.++```+nindent 4 $lots_of_text+```++The above will indent every line of text by 4 space characters and add a new+line to the beginning.++### replace++Perform simple string replacement.++It takes three arguments:++- string to replace+- string to replace with+- source string++```+"I Am Henry VIII" | replace " " "-"+```++The above will produce `I-Am-Henry-VIII`++### plural++Pluralize a string.++```+len $fish | plural "one anchovy" "many anchovies"+```++In the above, if the length of the string is 1, the first argument will be+printed (`one anchovy`). Otherwise, the second argument will be printed+(`many anchovies`).++The arguments are:++- singular string+- plural string+- length integer++NOTE: Helm does not currently support languages with more complex pluralization+rules. And `0` is considered a plural because the English language treats it+as such (`zero anchovies`).++### snakecase++Convert string from camelCase to snake_case.++```+snakecase "FirstName"+```++This above will produce `first_name`.++### camelcase++Convert string from snake_case to CamelCase++```+camelcase "http_server"+```++This above will produce `HttpServer`.++### kebabcase++Convert string from camelCase to kebab-case.++```+kebabcase "FirstName"+```++This above will produce `first-name`.++### swapcase++Swap the case of a string using a word based algorithm.++Conversion algorithm:++- Upper case character converts to Lower case+- Title case character converts to Lower case+- Lower case character after Whitespace or at start converts to Title case+- Other Lower case character converts to Upper case+- Whitespace is defined by unicode.IsSpace(char)++```+swapcase "This Is A.Test"+```++This above will produce `tHIS iS a.tEST`.++### shuffle++Shuffle a string.++```+shuffle "hello"+```++The above will randomize the letters in `hello`, perhaps producing `oelhl`.++## Type Conversion Functions++The following type conversion functions are provided by Helm:++- `atoi`: Convert a string to an integer.+- `float64`: Convert to a `float64`.+- `int`: Convert to an `int` at the system's width.+- `int64`: Convert to an `int64`.+- `toDecimal`: Convert a unix octal to a `int64`.+- `toString`: Convert to a string.+- `toStrings`: Convert a list, slice, or array to a list of strings.+- `toJson` (`mustToJson`): Convert list, slice, array, dict, or object to JSON.+- `toPrettyJson` (`mustToPrettyJson`): Convert list, slice, array, dict, or object to indented JSON.+- `toRawJson` (`mustToRawJson`): Convert list, slice, array, dict, or object to JSON with HTML characters unescaped.++Only `atoi` requires that the input be a specific type. The others will attempt+to convert from any type to the destination type. For example, `int64` can convert+floats to ints, and it can also convert strings to ints.++### toStrings++Given a list-like collection, produce a slice of strings.++```+list 1 2 3 | toStrings+```++The above converts `1` to `"1"`, `2` to `"2"`, and so on, and then returns+them as a list.++### toDecimal++Given a unix octal permission, produce a decimal.++```+"0777" | toDecimal+```++The above converts `0777` to `511` and returns the value as an int64.++### toJson, mustToJson++The `toJson` function encodes an item into a JSON string. If the item cannot be converted to JSON the function will return an empty string.+`mustToJson` will return an error in case the item cannot be encoded in JSON.++```+toJson .Item+```++The above returns JSON string representation of `.Item`.++### toPrettyJson, mustToPrettyJson++The `toPrettyJson` function encodes an item into a pretty (indented) JSON string.++```+toPrettyJson .Item+```++The above returns indented JSON string representation of `.Item`.++### toRawJson, mustToRawJson++The `toRawJson` function encodes an item into JSON string with HTML characters unescaped.++```+toRawJson .Item+```++The above returns unescaped JSON string representation of `.Item`.++## Regular Expressions++Helm includes the following regular expression functions: [regexFind (mustRegexFind)](#regexfindall-mustregexfindall), [regexFindAll (mustRegexFindAll)](#regexfind-mustregexfind), [regexMatch (mustRegexMatch)](#regexmatch-mustregexmatch), [regexReplaceAll (mustRegexReplaceAll)](#regexreplaceall-mustregexreplaceall), [regexReplaceAllLiteral (mustRegexReplaceAllLiteral)](#regexreplaceallliteral-mustregexreplaceallliteral), [regexSplit (mustRegexSplit)](#regexsplit-mustregexsplit).++### regexMatch, mustRegexMatch++Returns true if the input string contains any match of the regular expression.++```+regexMatch "^[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\\.[A-Za-z]{2,}$" "test@acme.com"+```++The above produces `true`++`regexMatch` panics if there is a problem and `mustRegexMatch` returns an error to the+template engine if there is a problem.++### regexFindAll, mustRegexFindAll++Returns a slice of all matches of the regular expression in the input string.+The last parameter n determines the number of substrings to return, where -1 means return all matches++```+regexFindAll "[2,4,6,8]" "123456789" -1+```++The above produces `[2 4 6 8]`++`regexFindAll` panics if there is a problem and `mustRegexFindAll` returns an error to the+template engine if there is a problem.++### regexFind, mustRegexFind++Return the first (left most) match of the regular expression in the input string++```+regexFind "[a-zA-Z][1-9]" "abcd1234"+```++The above produces `d1`++`regexFind` panics if there is a problem and `mustRegexFind` returns an error to the+template engine if there is a problem.++### regexReplaceAll, mustRegexReplaceAll++Returns a copy of the input string, replacing matches of the Regexp with the replacement string replacement.+Inside string replacement, $ signs are interpreted as in Expand, so for instance $1 represents the text of the first submatch++```+regexReplaceAll "a(x*)b" "-ab-axxb-" "${1}W"+```++The above produces `-W-xxW-`++`regexReplaceAll` panics if there is a problem and `mustRegexReplaceAll` returns an error to the+template engine if there is a problem.++### regexReplaceAllLiteral, mustRegexReplaceAllLiteral++Returns a copy of the input string, replacing matches of the Regexp with the replacement string replacement+The replacement string is substituted directly, without using Expand++```+regexReplaceAllLiteral "a(x*)b" "-ab-axxb-" "${1}"+```++The above produces `-${1}-${1}-`++`regexReplaceAllLiteral` panics if there is a problem and `mustRegexReplaceAllLiteral` returns an error to the+template engine if there is a problem.++### regexSplit, mustRegexSplit++Slices the input string into substrings separated by the expression and returns a slice of the substrings between those expression matches. The last parameter `n` determines the number of substrings to return, where `-1` means return all matches++```+regexSplit "z+" "pizza" -1+```++The above produces `[pi a]`++`regexSplit` panics if there is a problem and `mustRegexSplit` returns an error to the+template engine if there is a problem.++## Cryptographic and Security Functions++Helm provides some advanced cryptographic functions. They include [adler32sum](#adler32sum), [buildCustomCert](#buildcustomcert), [decryptAES](#decryptaes), [derivePassword](#derivepassword), [encryptAES](#encryptaes), [genCA](#genca), [genPrivateKey](#genprivatekey), [genSelfSignedCert](#genselfsignedcert), [genSignedCert](#gensignedcert), [htpasswd](#htpasswd), [sha1sum](#sha1sum), and [sha256sum](#sha256sum).++### sha1sum++The `sha1sum` function receives a string, and computes it's SHA1 digest.++```+sha1sum "Hello world!"+```++### sha256sum++The `sha256sum` function receives a string, and computes it's SHA256 digest.++```+sha256sum "Hello world!"+```++The above will compute the SHA 256 sum in an "ASCII armored" format that is+safe to print.++### adler32sum++The `adler32sum` function receives a string, and computes its Adler-32 checksum.++```+adler32sum "Hello world!"+```++### htpasswd++The `htpasswd` function takes a `username` and `password` and generates a `bcrypt` hash of the password. The result can be used for basic authentication on an [Apache HTTP Server](https://httpd.apache.org/docs/2.4/misc/password_encryptions.html#basic).++```+htpasswd "myUser" "myPassword"+```++Note that it is insecure to store the password directly in the template.++### derivePassword++The `derivePassword` function can be used to derive a specific password based on+some shared "master password" constraints. The algorithm for this is+[well specified](https://masterpassword.app/masterpassword-algorithm.pdf).++```+derivePassword 1 "long" "password" "user" "example.com"+```++Note that it is considered insecure to store the parts directly in the template.++### genPrivateKey++The `genPrivateKey` function generates a new private key encoded into a PEM+block.++It takes one of the values for its first param:++- `ecdsa`: Generate an elliptic curve DSA key (P256)+- `dsa`: Generate a DSA key (L2048N256)+- `rsa`: Generate an RSA 4096 key++### buildCustomCert++The `buildCustomCert` function allows customizing the certificate.++It takes the following string parameters:++- A base64 encoded PEM format certificate+- A base64 encoded PEM format private key++It returns a certificate object with the following attributes:++- `Cert`: A PEM-encoded certificate+- `Key`: A PEM-encoded private key++Example:++```+$ca := buildCustomCert "base64-encoded-ca-crt" "base64-encoded-ca-key"+```++Note that the returned object can be passed to the `genSignedCert` function+to sign a certificate using this CA.++### genCA++The `genCA` function generates a new, self-signed x509 certificate authority.++It takes the following parameters:++- Subject's common name (cn)+- Cert validity duration in days++It returns an object with the following attributes:++- `Cert`: A PEM-encoded certificate+- `Key`: A PEM-encoded private key++Example:++```+$ca := genCA "foo-ca" 365+```++Note that the returned object can be passed to the `genSignedCert` function+to sign a certificate using this CA.++### genSelfSignedCert++The `genSelfSignedCert` function generates a new, self-signed x509 certificate.++It takes the following parameters:++- Subject's common name (cn)+- Optional list of IPs; may be nil+- Optional list of alternate DNS names; may be nil+- Cert validity duration in days++It returns an object with the following attributes:++- `Cert`: A PEM-encoded certificate+- `Key`: A PEM-encoded private key++Example:++```+$cert := genSelfSignedCert "foo.com" (list "10.0.0.1" "10.0.0.2") (list "bar.com" "bat.com") 365+```++### genSignedCert++The `genSignedCert` function generates a new, x509 certificate signed by the+specified CA.++It takes the following parameters:++- Subject's common name (cn)+- Optional list of IPs; may be nil+- Optional list of alternate DNS names; may be nil+- Cert validity duration in days+- CA (see `genCA`)++Example:++```+$ca := genCA "foo-ca" 365+$cert := genSignedCert "foo.com" (list "10.0.0.1" "10.0.0.2") (list "bar.com" "bat.com") 365 $ca+```++### encryptAES++The `encryptAES` function encrypts text with AES-256 CBC and returns a base64 encoded string.++```+encryptAES "secretkey" "plaintext"+```++### decryptAES++The `decryptAES` function receives a base64 string encoded by the AES-256 CBC+algorithm and returns the decoded text.++```+"30tEfhuJSVRhpG97XCuWgz2okj7L8vQ1s6V9zVUPeDQ=" | decryptAES "secretkey"+```++## Date Functions++Helm includes the following date functions you can use in templates: [ago](#ago), [date](#date), [dateInZone](#dateinzone), [dateModify (mustDateModify)](#datemodify-mustdatemodify), [duration](#duration), [durationRound](#durationround), [htmlDate](#htmldate), [htmlDateInZone](#htmldateinzone), [now](#now), [toDate (mustToDate)](#todate-musttodate), and [unixEpoch](#unixepoch).++### now++The current date/time. Use this in conjunction with other date functions.++### ago++The `ago` function returns duration from time.Now in seconds resolution.++```+ago .CreatedAt"

Extra quotation mark here

mattfarina

comment created time in 2 months

pull request commentMasterminds/goutils

added function DefaultString, DefaultIfBlank

Thanks!

misoboy

comment created time in 2 months

push eventMasterminds/goutils

chiseok.song

commit sha 740ce87c3876f39c1aebbabf108d48a2c894c31d

added function DefaultString, DefaultIfBlank

view details

Matt Butcher

commit sha 864fea799ab6516ec883dc052a9a0b15f1e529dd

Merge pull request #28 from misoboy/master added function DefaultString, DefaultIfBlank

view details

push time in 2 months

PR merged Masterminds/goutils

added function DefaultString, DefaultIfBlank

added function DefaultString, DefaultIfBlank for stringutils.go and added Test case

+46 -0

1 comment

2 changed files

misoboy

pr closed time in 2 months

delete branch technosophos/k8s-helm

delete branch : fix/v2-better-plugin-archive-extraction

delete time in 2 months

push eventhelm/helm

Matt Butcher

commit sha def975f556a8d32307306be119a5f3b0411224d9

backported archive improvements from v3 (#8318) Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

view details

push time in 2 months

PR merged helm/helm

backported archive improvements from v3 needs-pick size/L

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

<!-- Thanks for sending a pull request! Here are some tips for you:

  1. Make sure to read the Contributing Guide before submitting your PR: https://github.com/helm/helm/blob/master/CONTRIBUTING.md
  2. If this PR closes another issue, add 'closes #<issue number>' somewhere in the PR summary. GitHub will automatically close that issue when this PR gets merged. Alternatively, adding 'refs #<issue number>' will not close the issue, but help provide the reviewer more context.-->

What this PR does / why we need it:

This backports improvements to the HTTP plugin installer.

Special notes for your reviewer:

If applicable:

  • [ ] this PR contains documentation
  • [x] this PR contains unit tests
  • [x] this PR has been tested for backwards compatibility
+154 -4

0 comment

2 changed files

technosophos

pr closed time in 2 months

PR opened helm/helm

backported archive improvements from v3 needs-pick

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

<!-- Thanks for sending a pull request! Here are some tips for you:

  1. Make sure to read the Contributing Guide before submitting your PR: https://github.com/helm/helm/blob/master/CONTRIBUTING.md
  2. If this PR closes another issue, add 'closes #<issue number>' somewhere in the PR summary. GitHub will automatically close that issue when this PR gets merged. Alternatively, adding 'refs #<issue number>' will not close the issue, but help provide the reviewer more context.-->

What this PR does / why we need it:

This backports improvements to the HTTP plugin installer.

Special notes for your reviewer:

If applicable:

  • [ ] this PR contains documentation
  • [x] this PR contains unit tests
  • [x] this PR has been tested for backwards compatibility
+154 -4

0 comment

2 changed files

pr created time in 2 months

delete branch technosophos/k8s-helm

delete branch : fix/better-plugin-archive-extractor

delete time in 2 months

push eventhelm/helm

Matt Butcher

commit sha b6bbe4f08bbb98eadd6c9cd726b08a5c639908b3

Improve the extractor and add tests (#8317) Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

view details

push time in 2 months

PR merged helm/helm

Improve the extractor and add tests needs-pick size/M

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

<!-- Thanks for sending a pull request! Here are some tips for you:

  1. Make sure to read the Contributing Guide before submitting your PR: https://github.com/helm/helm/blob/master/CONTRIBUTING.md
  2. If this PR closes another issue, add 'closes #<issue number>' somewhere in the PR summary. GitHub will automatically close that issue when this PR gets merged. Alternatively, adding 'refs #<issue number>' will not close the issue, but help provide the reviewer more context.-->

What this PR does / why we need it:

This improves the handling of tar file extraction in the plugin extraction over HTTP.

Special notes for your reviewer:

If applicable:

  • [ ] this PR contains documentation
  • [x] this PR contains unit tests
  • [x] this PR has been tested for backwards compatibility
+89 -2

0 comment

2 changed files

technosophos

pr closed time in 2 months

PR opened helm/helm

Improve the extractor and add tests

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

<!-- Thanks for sending a pull request! Here are some tips for you:

  1. Make sure to read the Contributing Guide before submitting your PR: https://github.com/helm/helm/blob/master/CONTRIBUTING.md
  2. If this PR closes another issue, add 'closes #<issue number>' somewhere in the PR summary. GitHub will automatically close that issue when this PR gets merged. Alternatively, adding 'refs #<issue number>' will not close the issue, but help provide the reviewer more context.-->

What this PR does / why we need it:

This improves the handling of tar file extraction in the plugin extraction over HTTP.

Special notes for your reviewer:

If applicable:

  • [ ] this PR contains documentation
  • [x] this PR contains unit tests
  • [x] this PR has been tested for backwards compatibility
+89 -2

0 comment

2 changed files

pr created time in 2 months

create barnchtechnosophos/k8s-helm

branch : fix/v2-better-plugin-archive-extraction

created branch time in 2 months

push eventtechnosophos/k8s-helm

Matt Butcher

commit sha b2695b05d41577a1e104ec91c0b294335c9afbfa

Improve the extractor and add tests Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

view details

push time in 2 months

push eventtechnosophos/k8s-helm

Matt Butcher

commit sha e1c293d600cce9335ea9b9a0e290bdf4c0d02879

Improve the extractor and add tests Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

view details

push time in 2 months

push eventtechnosophos/k8s-helm

Matt Butcher

commit sha c52032f586c69e4bd0d69432e71044e944fd21a7

Improve the extractor and add tests Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

view details

push time in 2 months

CommitCommentEvent
CommitCommentEvent
CommitCommentEvent

push eventtechnosophos/k8s-helm

Matt Butcher

commit sha eed9cefac6eb57ebce2d0b23b46468d8f3115104

Improve the extractor and add tests Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

view details

push time in 2 months

pull request commenthelm/helm

Lint dependencies

Fixed and ready for re-review

technosophos

comment created time in 2 months

Pull request review commenthelm/helm

Lint dependencies

+/*+Copyright The Helm Authors.++Licensed under the Apache License, Version 2.0 (the "License");+you may not use this file except in compliance with the License.+You may obtain a copy of the License at++    http://www.apache.org/licenses/LICENSE-2.0++Unless required by applicable law or agreed to in writing, software+distributed under the License is distributed on an "AS IS" BASIS,+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.+See the License for the specific language governing permissions and+limitations under the License.+*/+package rules++import (+	"os"+	"path/filepath"+	"testing"++	"helm.sh/helm/v3/internal/test/ensure"+	"helm.sh/helm/v3/pkg/chart"+	"helm.sh/helm/v3/pkg/chartutil"+	"helm.sh/helm/v3/pkg/lint/support"+)++const (+	badChartDepsDir = "testdata/lint-deps"

Done

technosophos

comment created time in 2 months

push eventtechnosophos/k8s-helm

Matt Butcher

commit sha 70cc08f14a18d889306c3b941cd1ad9fa83da0ed

replaced on-disk fixtures with in-memory fixtures Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

view details

push time in 2 months

push eventtechnosophos/k8s-helm

Matt Butcher

commit sha a15ecde5c015498bf7ed15341d51e94b4c6575fe

Improve the extractor and add tests Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

view details

push time in 2 months

push eventtechnosophos/k8s-helm

Matt Butcher

commit sha 45fa41a616c14a965bcfd69cb7979d1bb9dfc83f

Improve the extractor and add tests Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

view details

push time in 2 months

more