cnabio / cnab-spec

Cloud Native Application Bundle Specification
https://cnab.io
Other
958 stars 99 forks source link

Make invocation images optional #358

Closed glyn closed 4 years ago

glyn commented 4 years ago

Fixes https://github.com/cnabio/cnab-spec/issues/352

radu-matei commented 4 years ago

This PR does make invocation images optional syntactically in the specification text, but it does not have any details as to how potential runtimes should handle things like parameters, credentials, or outputs.

As far as I can tell, this is the only addition to the runtime spec:

If an attempt is made to execute the run tool of a bundle with no invocation image, the runtime MUST exit with an error. A runtime MAY support CNAB actions on bundles with no invocation image (e.g. by handing the action itself and not attempting to execute the bundle's run tool).

glyn commented 4 years ago

This PR does make invocation images optional syntactically in the specification text, but it does not have any details as to how potential runtimes should handle things like parameters, credentials, or outputs.

Yes, I need to add some text about that, thanks.

glyn commented 4 years ago

@radu-matei I've added some text about parameters, credentials, and outputs. I've also provided a non-normative summary in 806-declarative-installation-support.md.

carolynvs commented 4 years ago

@glyn This pull request was originally scoped to "make invocation images optional". However the latest changes make the majority of the CNAB specification optional for bundles that don't use invocation images.

A bundle that doesn't use invocation images also doesn't use: parameters, credentials and outputs. This feels unnecessary. I would prefer that any proposal includes a solution that keeps the existing (useful) features of the CNAB spec and sticks to the original scope of only making invocation images optional.

glyn commented 4 years ago

@glyn This pull request was originally scoped to "make invocation images optional". However the latest changes make the majority of the CNAB specification optional for bundles that don't use invocation images.

What could be normative and worth saying about parameters, credentials, and outputs for bundles with no invocation image? Maybe I've misunderstood the intention behind those features and how closely they are tied to invocation images.

A bundle that doesn't use invocation images also doesn't use: parameters, credentials and outputs. This feels unnecessary. I would prefer that any proposal includes a solution that keeps the existing (useful) features of the CNAB spec and sticks to the original scope of only making invocation images optional.

I understand. Please note that I deliberately used the word SHOULD in sentences such as:

If a bundle has no invocation images, the parameters section SHOULD be omitted.

The idea was to allow parameters, credentials, and outputs to be used if and only if the runtime(s) that the bundle is targetting can handle them. I wonder if there's a better way of expressing this. How about, for example:

If a bundle has no invocation images, the parameters section MAY be omitted.

Any thoughts greatly appreciated.

glyn commented 4 years ago

After discussion in the CNAB Community Call on 18 March 202, it appears that making invocation images optional bifurcates the spec and makes interoperability more difficult. Closing.