Merge branch 'master' into master

This commit is contained in:
Simon Fels 2018-06-05 17:00:06 +02:00 committed by GitHub
commit cdfa35e043
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 33 additions and 7 deletions

View file

@ -1,8 +1,12 @@
Make sure you are running the latest version of Anbox before reporting an issue.
1. Please check that no similar bug is already reported. Have a look on the list of open bugs at https://github.com/anbox/anbox/issues
2. Make sure you are running the latest version of Anbox before reporting an issue. Update snap to latest: `snap refresh --devmode --edge anbox`
3. Make sure you have debug logs enabled:
`sudo snap set anbox debug.enable=true`
4. Reproduce the error while debug logs enabled.
5. Run the anbox logs collection utility and attach the tar file.
`sudo /snap/bin/anbox.collect-bug-info `
Please also check that no similar bug is already reported. Have a look on the list of open bugs at https://github.com/anbox/anbox/issues
** Please paste the result of `anbox system-info` below:**
6. ** Please paste the result of `anbox system-info` below:**
```
[please paste printout of `anbox system-info` here]
```
@ -14,3 +18,4 @@ Please also check that no similar bug is already reported. Have a look on the li
**Additional info:**

1
.gitignore vendored
View file

@ -2,7 +2,6 @@ build*/
parts/
stage/
prime/
snap/
android-images/
*.snap
CMakeLists.txt.user

View file

@ -24,8 +24,8 @@ echo "Collecting anbox log files ... "
set -x
# Collect several things which are of interest for bug reports
cp /var/snap/anbox/common/data/system.log $TMPDIR || true
cp /var/snap/anbox/containers/lxc-monitord.log $TMPDIR || true
cp /var/snap/anbox/logs/container.log $TMPDIR || true
cp /var/snap/anbox/common/containers/lxc-monitord.log $TMPDIR || true
cp /var/snap/anbox/common/logs/container.log $TMPDIR || true
$SNAP/command-anbox.wrapper system-info > $TMPDIR/system-info.log 2>&1 || true
if [ -e /etc/systemd/system/snap.anbox.container-manager.service ]; then

View file

@ -43,6 +43,10 @@ start() {
$SNAP/sbin/apparmor_parser -r $SNAP/apparmor/anbox-container.aa
fi
if [ -e "$SNAP_COMMON"/.enable_debug ]; then
export ANBOX_LOG_LEVEL=debug
fi
exec $AA_EXEC $SNAP/bin/anbox-wrapper.sh container-manager \
--data-path=$DATA_PATH \
--android-image=$ANDROID_IMG \

View file

@ -29,4 +29,8 @@ export XDG_DATA_HOME="$SNAP_USER_COMMON/app-data"
# configured but the actual EGL implementation is missing.
export __EGL_VENDOR_LIBRARY_DIRS="$SNAP/glvnd"
if [ -e "$SNAP_COMMON"/.enable_debug ]; then
export ANBOX_LOG_LEVEL=debug
fi
exec $SNAP/usr/bin/anbox $@

9
snap/hooks/configure vendored Executable file
View file

@ -0,0 +1,9 @@
#!/bin/sh
if [ "$(snapctl get debug.enable)" = true ]; then
touch "$SNAP_COMMON"/.enable_debug
else
rm -f "$SNAP_COMMON"/.enable_debug
fi
exit 0

View file

@ -72,6 +72,7 @@ parts:
x86_64)
IMAGE_PATH="2018/05/23"
IMAGE_NAME="android_amd64.img"
IMAGE_HASH="cbcb8c4740ed38dbc243122df2d8d87511a9c8dcc162781f2eabb5dc1ea079fe"
;;
*)
echo "ERROR: Unknown architecture $ARCH"
@ -83,6 +84,10 @@ parts:
# expects the downloaded file to be an archive it can extract.
echo "Downloading image..."
wget http://build.anbox.io/android-images/$IMAGE_PATH/$IMAGE_NAME
echo "$IMAGE_HASH $IMAGE_NAME" > image-hash
sha256sum -c image-hash
mv $IMAGE_NAME $SNAPCRAFT_PART_INSTALL/android.img
fi