Skip to content

add SIP - packaging components - #3697

Draft
michelleN wants to merge 1 commit into
spinframework:mainfrom
michelleN:componenttoml
Draft

add SIP - packaging components#3697
michelleN wants to merge 1 commit into
spinframework:mainfrom
michelleN:componenttoml

Conversation

@michelleN

Copy link
Copy Markdown
Collaborator

No description provided.

Signed-off-by: Michelle Dhanani <mdhanani@akamai.com>

@itowlson itowlson left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good stuff, thanks for getting this under way!

| `environments_variables` | Environment variables the component needs. Each entry is a bare name, or `{ name, default }`. |
| `files` | Files the component may read: a glob, or `{ source, destination }` mount. |

`[requires]` is descriptive: it documents what an application must provide when it

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like this emphasis. The component cannot grant itself the permissions because we can't trust it, but we need to know what it wants from us.

(no action, just wanted to applaud)


### Building a component

`spin build` recognizes a component manifest, runs its `[build].command`, and embeds

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Recognises it by the manifest version declaration?

pre-built).

Only `spin build` operates on component manifests. `spin up`, `spin deploy`, and
similar commands continue to require an application manifest, because a lone

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PEDANTRY CORNER: spin up -f bare.wasm does work. (but your point is still right of course)

only a `source`. A `watch` field (globs for `spin watch`) is intentionally *not*
included yet — `spin watch` does not operate on component manifests, so the field
would have no effect. It will be added together with `spin watch` support for
component manifests (see [Future work](#future-work)).

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct to say a standalone component cannot have dependencies?

```

- The version portion is a semver requirement; when omitted, the latest
non-yanked release is pulled.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm getting a bit confused across OCI and wkg at this point, sorry. The draft uses OCI terminology and references in some places, and wkg in others (which is what is mentioned in the preamble).

- The version portion is a semver requirement; when omitted, the latest
non-yanked release is pulled.
- `--output` selects where the component Wasm is written; it defaults to
`<name>.wasm` in the current directory.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

spin registry pull with applications puts them in the Spin cache I believe.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants