Merge ~kzapalowicz/snappy-hwe-snaps/+git/pulseaudio:feature/fix-runtime-issues into ~snappy-hwe-team/snappy-hwe-snaps/+git/pulseaudio:master
- Git
- lp:~kzapalowicz/snappy-hwe-snaps/+git/pulseaudio
- feature/fix-runtime-issues
- Merge into master
Status: | Merged |
---|---|
Approved by: | Simon Fels |
Approved revision: | 0792791574a2772161f8f51082ceef5db7885a12 |
Merged at revision: | c3e5e6edc7f6eb369945d7d8a0837a3dc60f2044 |
Proposed branch: | ~kzapalowicz/snappy-hwe-snaps/+git/pulseaudio:feature/fix-runtime-issues |
Merge into: | ~snappy-hwe-team/snappy-hwe-snaps/+git/pulseaudio:master |
Diff against target: |
136 lines (+27/-11) 8 files modified
bin/pactl (+5/-0) bin/paplay (+5/-0) bin/parec (+5/-0) run-tests.sh (+1/-1) snapcraft.yaml (+3/-3) tests/image/create-image.sh (+1/-1) tests/lib/prepare-all.sh (+2/-1) tests/lib/prepare.sh (+5/-5) |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
System Enablement Bot | continuous-integration | Approve | |
Simon Fels | Approve | ||
Matteo Croce (community) | Approve | ||
Review via email: mp+313340@code.launchpad.net |
Commit message
Fix issues related with running the snap on the target system.
The introduced changes deal with:
1.
SecComp complaining of using send syscall
2.
pactl, parec and paplay commands trying to create the /run/user/[0-9]*
which is forbidden by the AppArmor rules due to security reasons.
Description of the change
Fix issues related with running the snap on the target system.
Matteo Croce (teknoraver) : | # |
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:76b263a01c1
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
Simon Fels (morphis) : | # |
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:60fd5ccfc31
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:60fd5ccfc31
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
Matteo Croce (teknoraver) : | # |
Simon Fels (morphis) wrote : | # |
LGTM, but we need to wait until the CI is fixed.
Simon Fels (morphis) : | # |
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:60fd5ccfc31
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:60fd5ccfc31
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:60fd5ccfc31
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:60fd5ccfc31
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:926844517a1
https:/
Executed test runs:
SUCCESS: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:926844517a1
https:/
Executed test runs:
SUCCESS: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:60fd5ccfc31
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:926844517a1
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:60fd5ccfc31
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:926844517a1
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:926844517a1
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:926844517a1
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:926844517a1
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
Simon Fels (morphis) wrote : | # |
The problem the CI sees here
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
libudev-dev : Depends: libudev1 (= 229-4ubuntu13) but 229-4ubuntu13+ppa1 is to be installed
E: Unable to correct problems, you have held broken packages.
is caused by the ubuntu-image ppa (https:/
As we can safely update from 229-4ubuntu13+ppa1 to 229-4ubuntu13 (both include the same fix) and additional
$ apt upgrade --yes --force-yes
in the script should solve this problem.
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:99ba4033b84
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:99ba4033b84
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:ef3646be246
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:ef3646be246
https:/
Executed test runs:
SUCCESS: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:0792791574a
https:/
Executed test runs:
SUCCESS: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:0792791574a
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild:
https:/
System Enablement Bot (system-enablement-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:0792791574a
https:/
Executed test runs:
SUCCESS: https:/
None: https:/
Click here to trigger a rebuild:
https:/
Preview Diff
1 | diff --git a/bin/pactl b/bin/pactl | |||
2 | index ad5e799..97e23b2 100755 | |||
3 | --- a/bin/pactl | |||
4 | +++ b/bin/pactl | |||
5 | @@ -14,6 +14,11 @@ | |||
6 | 14 | # You should have received a copy of the GNU General Public License | 14 | # You should have received a copy of the GNU General Public License |
7 | 15 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | 15 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
8 | 16 | 16 | ||
9 | 17 | if [ $(id -u) -ne 0 ]; then | ||
10 | 18 | echo "This script must be run as root" 1>&2 | ||
11 | 19 | exit 1 | ||
12 | 20 | fi | ||
13 | 21 | |||
14 | 17 | export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$SNAP/usr/lib/pulseaudio:$SNAP/usr/lib/pulse-8.0/modules/ | 22 | export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$SNAP/usr/lib/pulseaudio:$SNAP/usr/lib/pulse-8.0/modules/ |
15 | 18 | export PULSE_CLIENTCONFIG=$SNAP/etc/pulse/client.conf | 23 | export PULSE_CLIENTCONFIG=$SNAP/etc/pulse/client.conf |
16 | 19 | export HOME=$SNAP_DATA/home | 24 | export HOME=$SNAP_DATA/home |
17 | diff --git a/bin/paplay b/bin/paplay | |||
18 | index 4f83d77..a132d51 100755 | |||
19 | --- a/bin/paplay | |||
20 | +++ b/bin/paplay | |||
21 | @@ -14,6 +14,11 @@ | |||
22 | 14 | # You should have received a copy of the GNU General Public License | 14 | # You should have received a copy of the GNU General Public License |
23 | 15 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | 15 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
24 | 16 | 16 | ||
25 | 17 | if [ $(id -u) -ne 0 ]; then | ||
26 | 18 | echo "This script must be run as root" 1>&2 | ||
27 | 19 | exit 1 | ||
28 | 20 | fi | ||
29 | 21 | |||
30 | 17 | export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$SNAP/usr/lib/pulseaudio:$SNAP/usr/lib/pulse-8.0/modules/ | 22 | export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$SNAP/usr/lib/pulseaudio:$SNAP/usr/lib/pulse-8.0/modules/ |
31 | 18 | export PULSE_CLIENTCONFIG=$SNAP/etc/pulse/client.conf | 23 | export PULSE_CLIENTCONFIG=$SNAP/etc/pulse/client.conf |
32 | 19 | export HOME=$SNAP_DATA/home | 24 | export HOME=$SNAP_DATA/home |
33 | diff --git a/bin/parec b/bin/parec | |||
34 | index 0c1cafd..269e0f8 100755 | |||
35 | --- a/bin/parec | |||
36 | +++ b/bin/parec | |||
37 | @@ -14,6 +14,11 @@ | |||
38 | 14 | # You should have received a copy of the GNU General Public License | 14 | # You should have received a copy of the GNU General Public License |
39 | 15 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | 15 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
40 | 16 | 16 | ||
41 | 17 | if [ $(id -u) -ne 0 ]; then | ||
42 | 18 | echo "This script must be run as root" 1>&2 | ||
43 | 19 | exit 1 | ||
44 | 20 | fi | ||
45 | 21 | |||
46 | 17 | export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$SNAP/usr/lib/pulseaudio:$SNAP/usr/lib/pulse-8.0/modules/ | 22 | export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$SNAP/usr/lib/pulseaudio:$SNAP/usr/lib/pulse-8.0/modules/ |
47 | 18 | export PULSE_CLIENTCONFIG=$SNAP/etc/pulse/client.conf | 23 | export PULSE_CLIENTCONFIG=$SNAP/etc/pulse/client.conf |
48 | 19 | export HOME=$SNAP_DATA/home | 24 | export HOME=$SNAP_DATA/home |
49 | diff --git a/run-tests.sh b/run-tests.sh | |||
50 | index f2e9079..b4ce91b 100755 | |||
51 | --- a/run-tests.sh | |||
52 | +++ b/run-tests.sh | |||
53 | @@ -17,7 +17,7 @@ | |||
54 | 17 | set -ex | 17 | set -ex |
55 | 18 | 18 | ||
56 | 19 | image_name=ubuntu-core-16.img | 19 | image_name=ubuntu-core-16.img |
58 | 20 | channel=candidate | 20 | channel=stable |
59 | 21 | spread_opts= | 21 | spread_opts= |
60 | 22 | force_new_image=0 | 22 | force_new_image=0 |
61 | 23 | test_from_channel=0 | 23 | test_from_channel=0 |
62 | diff --git a/snapcraft.yaml b/snapcraft.yaml | |||
63 | index abb0b5f..8568c89 100644 | |||
64 | --- a/snapcraft.yaml | |||
65 | +++ b/snapcraft.yaml | |||
66 | @@ -18,13 +18,13 @@ apps: | |||
67 | 18 | slots: [service] | 18 | slots: [service] |
68 | 19 | pactl: | 19 | pactl: |
69 | 20 | command: bin/pactl | 20 | command: bin/pactl |
71 | 21 | plugs: [client] | 21 | plugs: [client, network] |
72 | 22 | paplay: | 22 | paplay: |
73 | 23 | command: bin/paplay | 23 | command: bin/paplay |
75 | 24 | plugs: [client,home] | 24 | plugs: [client, home, network] |
76 | 25 | parec: | 25 | parec: |
77 | 26 | command: bin/parec | 26 | command: bin/parec |
79 | 27 | plugs: [client] | 27 | plugs: [client, home, network] |
80 | 28 | config: | 28 | config: |
81 | 29 | command: bin/config | 29 | command: bin/config |
82 | 30 | 30 | ||
83 | diff --git a/tests/image/create-image.sh b/tests/image/create-image.sh | |||
84 | index e3c36e0..3aa1d13 100755 | |||
85 | --- a/tests/image/create-image.sh | |||
86 | +++ b/tests/image/create-image.sh | |||
87 | @@ -21,7 +21,7 @@ if [ $(id -u) -ne 0 ] ; then | |||
88 | 21 | exit 1 | 21 | exit 1 |
89 | 22 | fi | 22 | fi |
90 | 23 | 23 | ||
92 | 24 | channel=candidate | 24 | channel=stable |
93 | 25 | if [ ! -z "$1" ] ; then | 25 | if [ ! -z "$1" ] ; then |
94 | 26 | channel=$1 | 26 | channel=$1 |
95 | 27 | fi | 27 | fi |
96 | diff --git a/tests/lib/prepare-all.sh b/tests/lib/prepare-all.sh | |||
97 | index e3178fd..a65d357 100644 | |||
98 | --- a/tests/lib/prepare-all.sh | |||
99 | +++ b/tests/lib/prepare-all.sh | |||
100 | @@ -6,12 +6,13 @@ if [ -n "$SNAP_CHANNEL" ] ; then | |||
101 | 6 | exit 0 | 6 | exit 0 |
102 | 7 | fi | 7 | fi |
103 | 8 | 8 | ||
105 | 9 | # Setup classic snap and build the network-manager snap in there | 9 | # Setup classic snap and build the pulseaudio snap in there |
106 | 10 | snap install --devmode --beta classic | 10 | snap install --devmode --beta classic |
107 | 11 | cat <<-EOF > /home/test/build-snap.sh | 11 | cat <<-EOF > /home/test/build-snap.sh |
108 | 12 | #!/bin/sh | 12 | #!/bin/sh |
109 | 13 | set -ex | 13 | set -ex |
110 | 14 | apt update | 14 | apt update |
111 | 15 | apt upgrade --yes --force-yes | ||
112 | 15 | apt install -y --force-yes snapcraft | 16 | apt install -y --force-yes snapcraft |
113 | 16 | cd /home/pulseaudio | 17 | cd /home/pulseaudio |
114 | 17 | snapcraft clean | 18 | snapcraft clean |
115 | diff --git a/tests/lib/prepare.sh b/tests/lib/prepare.sh | |||
116 | index 4b360b5..60a45e9 100644 | |||
117 | --- a/tests/lib/prepare.sh | |||
118 | +++ b/tests/lib/prepare.sh | |||
119 | @@ -31,12 +31,12 @@ if [ -n "$SNAP_CHANNEL" ] ; then | |||
120 | 31 | echo "USING-CHANNEL" | 31 | echo "USING-CHANNEL" |
121 | 32 | else | 32 | else |
122 | 33 | echo "INSTALLING-PULSEAUDIO-SNAP" | 33 | echo "INSTALLING-PULSEAUDIO-SNAP" |
124 | 34 | # Install prebuilt pulseaudio snap | 34 | # Install prebuilt pulseaudio snap but first install if from |
125 | 35 | # the store to work around the fact that we are not allowed | ||
126 | 36 | # anymore to connect pulseaudio slot to a snap installed with | ||
127 | 37 | # --dangerous | ||
128 | 38 | snap install --beta pulseaudio | ||
129 | 35 | snap install --dangerous /home/pulseaudio/pulseaudio_*_amd64.snap | 39 | snap install --dangerous /home/pulseaudio/pulseaudio_*_amd64.snap |
130 | 36 | # As we have a snap which we build locally its unasserted and therefor | ||
131 | 37 | # we don't have any snap-declarations in place and need to manually | ||
132 | 38 | # connect all plugs. | ||
133 | 39 | snap connect pulseaudio:client pulseaudio:service | ||
134 | 40 | fi | 40 | fi |
135 | 41 | 41 | ||
136 | 42 | # Snapshot of the current snapd state for a later restore | 42 | # Snapshot of the current snapd state for a later restore |
FAILED: Continuous integration, rev:76b263a01c1 a7ff4b99cc72265 d9de57012c1c19 /jenkins. canonical. com/system- enablement/ job/generic- build-snap/ 469/ /jenkins. canonical. com/system- enablement/ job/generic- run-snap- spread- tests/212/ console /jenkins. canonical. com/system- enablement/ job/generic- update- snap-mp/ 377/console
https:/
Executed test runs:
FAILURE: https:/
None: https:/
Click here to trigger a rebuild: /jenkins. canonical. com/system- enablement/ job/generic- build-snap/ 469/rebuild
https:/