Comment 8 for bug 1577514

Revision history for this message
keshavbhatt (keshavnrj) wrote :

same happening with nwjs applications, nwjs is also based of chromium project and hence the application written on nwjs api cant run when packaged in snap format.

I ported my application from qt to nwjs cause same issue are happening with qwebengine which is again the based on chromium web engine qt migrated from webkit to chromium based webengine so, so Qt web-based application cant be packaged cause they will result in runtime crash.

- ERROR in strict confinement

= AppArmor =
Time: Dec 20 20:21:47
Log: apparmor="DENIED" operation="mknod" profile="snap.simple-gulp.messenger-snap" name="/dev/shm/.io.nwjs.MMIb0o" pid=9069 comm="Chrome_IOThread" requested_mask="c" denied_mask="c" fsuid=1000 ouid=1000
File: /dev/shm/.io.nwjs.MMIb0o (write)
Suggestion:
* adjust program to create files and directories in /dev/shm/snap.$SNAP_NAME.*

- ERROR in devmode confinement

= AppArmor =
Time: Dec 20 21:27:04
Log: apparmor="ALLOWED" operation="truncate" profile="snap.simple-gulp.messenger-snap" name="/dev/shm/.io.nwjs.onU4pg" pid=10628 comm="Chrome_FileUser" requested_mask="w" denied_mask="w" fsuid=1000 ouid=1000
File: /dev/shm/.io.nwjs.onU4pg (write)
Suggestion:
* adjust program to create files and directories in /dev/shm/snap.$SNAP_NAME.*

I also tried below in my wrapper script to change XDG_RUNTIME_DIR but it wont affect application from writing only to /dev/shm/ -- based on https://standards.freedesktop.org/basedir-spec/basedir-spec-latest.html

export XDG_RUNTIME_DIR=$XDG_CACHE_HOME/$SNAP_NAME/
mkdir -p $XDG_RUNTIME_DIR