Activity log for bug #1854046

Date Who What changed Old value New value Message
2019-11-26 12:02:06 Ian Johnson bug added bug
2019-11-26 19:39:05 Ian Johnson snapd: assignee Ian Johnson (anonymouse67)
2019-11-29 12:29:44 Sergio Cazzolato snapd: importance Undecided High
2019-12-02 19:53:03 Claudio Matsuoka snapd: status New Triaged
2019-12-04 17:17:54 Ian Johnson description with a snap.yaml that globally declares its plugs and also declares hook-specific plugs like so: ``` plugs: desktop: null desktop-legacy: null home: null joystick: null network: null opengl: null pulseaudio: null removable-media: null screen-inhibit-control: null unity7: null wayland: null x11: null hooks: install: plugs: - opengl command-chain: - snap/command-chain/snapcraft-runner ``` The hooks level plugs are ignored and not generated in the policy. You can test this with a simple configure hook that tries to read from /var/lib/snapd/libs/gl/libGL (an access which is provided by the opengl interface): ``` #!/bin/sh -e sha1sum /var/lib/snapd/lib/gl/libGL.so.1 ``` with a snap.yaml that globally declares its plugs and also declares app-specific plugs like so: ``` name: lp-1854046 version: '0.1' summary: regression test snap for LP bug 1854046 description: https://bugs.launchpad.net/snapd/+bug/1854046 base: core18 architectures: - amd64 confinement: strict grade: stable plugs: opengl: null apps: lp-1854046: command: snap/command-chain/snapcraft-runner $SNAP/command-lp-1854046.wrapper plugs: - opengl ``` The top level plugs are ignored and not generated in the policy for the hooks. You can see this with a simple configure hook that tries to read from /var/lib/snapd/libs/gl/libGL (an access which is provided by the opengl interface): ``` #!/bin/sh -e sha1sum /var/lib/snapd/lib/gl/libGL.so.1 ``` With this the snap will refuse to install.
2019-12-04 17:18:12 Ian Johnson summary global plugs in snap.yaml makes hook plugs ignored plugs apps in snap.yaml makes global plugs ignored for hooks
2019-12-04 17:18:25 Ian Johnson summary plugs apps in snap.yaml makes global plugs ignored for hooks plugs in apps in snap.yaml makes global plugs ignored for hooks
2019-12-05 15:19:13 Ian Johnson snapd: status Triaged Won't Fix
2019-12-05 15:19:18 Ian Johnson snapd: assignee Ian Johnson (anonymouse67)