cubeship
Templates

Inputs

The six ways a template asks the installer a question — a domain, a secret, a choice, and the fields each one takes.

An input is a question the template cannot answer for itself. Every input shares four fields:

KeyDefaultMeaning
keyRequired. What ${input.<key>} names elsewhere in the file.
typeRequired. One of the six below.
labelRequired, at least one character. What the installer reads.
helpnoneLonger text under the label.
requiredtrueWhether the installer must answer before installing.

Then, per type:

domain

Nothing further. This is the only way a template can name a host — see No domain. The installer supplies a hostname it controls, and ${input.<key>} is the only thing a domains.host may ever equal.

- key: domain
  type: domain
  label: Where the dashboard answers

text

KeyDefaultMeaning
defaultnonePre-filled, still editable.
patternnoneA regular expression the answer must match.

number

KeyDefaultMeaning
defaultnonePre-filled, still editable.
minnoneLower bound.
maxnoneUpper bound.

choice

KeyDefaultMeaning
defaultnoneWhich option is pre-selected.
optionsRequired, at least two strings.

secret

KeyDefaultMeaning
generatenoneA length in characters, at least 8.

With generate set, the instance produces the value and shows it once — nobody types a secret into a template. Without it, the installer types the value directly, the way a text input would.

- key: appSecret
  type: secret
  label: The app's session secret
  generate: 32

store

Nothing further. Asks the installer to pick an object store that already exists on the instance — the only way a template reaches S3 without carrying anyone's keys. The chosen key is then valid wherever a store key is expected, including attach.store.

Answering an input elsewhere in the file

An input's value is read with ${input.<key>} — in a domains.host, in env, nowhere else. See References for the full grammar.

On this page