snap.yaml change landed
Michael Vogt
michael.vogt at canonical.com
Thu Jan 28 13:19:24 UTC 2016
Hi,
we have landed support for meta/snap.yaml. This is the new internal
metadata format of a snap. It is cleaner than the previously used
meta/package.yaml and meta/readme.md and it also provides the required
syntax for the new skill (capabilities) system.
Snapcraft will manage most of this for you automatically. See also:
https://lists.ubuntu.com/archives/snappy-app-devel/2016-January/000530.html
For those interessted in the details, here are the key difference:
- meta/readme.md is gone and replaced with "summary" and
"description" in meta/snap.yaml
- the icon location must be meta/icon.{svg,png}
- the "binaries" and "services" key is gone, the new key is "apps"
and it is a map instead of a list (much easier to read)
- the security-* profiles are handled now by a "migration-skill".
The keys under the migration skill definition are the same as
the old security fields, for convenience when migrating.
Here is an example of the old `meta/package.yaml`:
"""
name: hello
version: 1.0
binaries:
- name: foo
security-template: template-one
- name: bar
security-template: template-two
"""
and the new `meta/snap.yaml`:
"""
name: hello
version: 1.0
summary: A friendly hello application
apps:
foo:
command: foo
uses: [migration-one]
bar:
command: bar
uses: [migration-two]
uses:
migration-one:
type: migration-skill
security-template: template-one
migration-two:
type: migration-skill
security-template: template-two
"""
As the skills system evolves the security handling will be transitioned.
This will be announced here.
Note that "frameworks" are supported currently in the meta/snap.yaml
to make the transition easier. These will eventually be handled via
skills as well.
If you have any questions or if anything is unclear, please let me
know!
Cheers,
Michael
More information about the snappy-devel
mailing list