Additional app-specific Snapcraft configuration
for the Electron app. This is different from SnapcraftConfig in that it is scoped
under apps.<app-name>.
Additional plugs for the Electron app,
which are necessary for the app to be a consumer of a feature in the system. Common features
can be set via the features option. To set any attributes for the plugs, set them in
the plugs option.
For example, if the app uses a DBus interface:
{
appPlugs: ['my-dbus-interface'],
plugs: {
'my-dbus-interface': {
interface: 'dbus',
name: 'com.example.my-interface',
bus: 'session'
}
}
}
plugs will be passed through directly to the generated snapcraft.yaml.
Additional slots for the Electron app,
which are necessary for the app to be a producer of a feature in the system. Common features
can be set via the features option. To set any attributes for the plugs, set them in
the slots option.
For example, if the app creates a DBus interface:
{
appSlots: ['my-dbus-interface'],
slots: {
'my-dbus-interface': {
interface: 'dbus',
name: 'com.example.my-interface',
bus: 'session'
}
}
}
slots will be passed through directly to the generated snapcraft.yaml.
Either the Node.js-formatted arch or Snap-formatted arch, used to specify the Snap's target arch.
Default: the host arch, via process.arch.
See the Snapcraft documentation.
Default: devmode
The longer description for the snap. Can contain newlines.
The absolute path to a custom Freedesktop.org desktop file template.
The directory where the .snap file is created.
Default: the current working directory.
The executable name of the Electron app, sans file extension. Corresponds
to the executableName option
in Electron Packager.
Default: either productName or name in package.json
Describes what functionality the Electron app needs, in order to work inside the Snap sandbox.
Example:
{
features: {
audio: true,
mpris: 'com.example.mpris',
webgl: true
}
}
Setting a feature to a false-y value does not disable the feature, only omitting the
feature from the Object does that.
Audio support via ALSA (replaces audio support if both are specified)
Audio support via PulseAudio.
Web browser functionality. This was originally enabled by default when using Electron ≥ 5.0.0, due to the setuid sandbox support. However, Snapcraft allows for use of the snap confined sandbox, particularly within strict confinement. We should encourage but not enforce the browser-sandbox plug.
MPRIS support.
If enabled, the interface name must be specified as the feature value.
Access the secret service (e.g., GNOME Keyring)
WebGL support (requires Mesa, etc.)
The quality grade of the Snap. See the Snapcraft documentation for valid values.
Default: devel
One or more hook scripts to be installed with
the Snap. The format of the Object is { hookName: pathToHookScript, […] }. Hook names
can be found in the Snapcraft documentation.
The name of the Snap package.
Default: name in package.json
See appPlugs for details.
See appSlots for details.
The absolute path to the snapcraft executable.
By default, it searches paths in the PATH environment variable.
A 78 character long summary for the Snap.
Default: description in package.json
The version of the Snap package.
Default: version in package.json
Any options that aren't specified here are passed through to the
snapcraft.yamlfile via SnapcraftConfig.