From 896577fb76dca54867296082c28ca56fbcef18c3 Mon Sep 17 00:00:00 2001 From: adnan Date: Mon, 11 Oct 2021 09:43:54 -0400 Subject: [PATCH] docs: update parameters doc with allowable types (#1792) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * update parameters doc with allowable types Signed-off-by: “adnan” * to squash: address wording issues Signed-off-by: “adnan” * to squash: add parameters-type section Signed-off-by: “adnan” --- docs/content/author-bundles.md | 8 ++++++++ docs/content/parameters.md | 12 +++++++----- 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/docs/content/author-bundles.md b/docs/content/author-bundles.md index 491d5ff6c..964bd6366 100644 --- a/docs/content/author-bundles.md +++ b/docs/content/author-bundles.md @@ -96,6 +96,14 @@ See [Using Mixins](/use-mixins) to learn more about how mixins work. Parameters are part of the [CNAB Spec](https://github.com/cnabio/cnab-spec/blob/master/101-bundle-json.md#parameters) and allow you to pass in configuration values when you execute the bundle. +### Parameter Types + +* string +* integer +* number +* boolean +* [file](#file-parameters) + Learn more about [how parameters work in Porter](/parameters/). ```yaml diff --git a/docs/content/parameters.md b/docs/content/parameters.md index 488f0386c..a90106703 100644 --- a/docs/content/parameters.md +++ b/docs/content/parameters.md @@ -5,11 +5,13 @@ aliases: - /how-parameters-work/ --- -When you are authoring a bundle, you can define what parameters your bundle -requires such as username and password values for a backing database, or the -region that a certain resource should be deployed in, etc. Then in your -action's steps you can reference the parameters using porter's template -language `{{ bundle.parameters.db_name }}`. +When you are authoring a bundle, you can define parameters that are required by +your bundle. These parameters are restricted to a list of [allowable data +types](/author-bundles/#parameter-types) and are used to define parameters such as +username and password values for a backing database, or the region that a +certain resource should be deployed in, etc. Then in your action's steps you can +reference the parameters using porter's template language `{{ +bundle.parameters.db_name }}`. Parameter values are resolved from a combination of supplied parameter set files, user-specified overrides and defaults defined by the bundle itself.