Core18 wayland snap stopped working

Hi,

I have a working snap that uses xwayland.

After rebuilding the snap. The app no longer runs.

Any ideas?

This is the error.

Sep 15 16:34:37 demo4 pam-app.pam-app[76037]: Errors from xkbcomp are not fatal to the X server
Sep 15 16:34:38 demo4 pam-app.pam-app[76041]: [76041:0915/163438.954548:ERROR:bus.cc(398)] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix")
Sep 15 16:34:38 demo4 pam-app.pam-app[76041]: [76041:0915/163438.954589:ERROR:bus.cc(398)] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix")
Sep 15 16:34:38 demo4 pam-app.pam-app[76041]: [76041:0915/163438.955231:ERROR:platform_shared_memory_region_posix.cc(217)] Creating shared memory in /dev/shm/.org.chromium.Chromium.AV4DNX failed: Permission denied (13)
Sep 15 16:34:38 demo4 pam-app.pam-app[76041]: [76041:0915/163438.955289:ERROR:platform_shared_memory_region_posix.cc(217)] Creating shared memory in /dev/shm/.org.chromium.Chromium.jxBFHv failed: Permission denied (13)
Sep 15 16:34:38 demo4 pam-app.pam-app[76068]: [0915/163438.955337:ERROR:scoped_ptrace_attach.cc(27)] ptrace: Operation not permitted (1)
Sep 15 16:34:38 demo4 pam-app.pam-app[75830]: /snap/pam-app/x5/bin/xwayland-kiosk-launch: line 151: 76041 Illegal instruction     "$@"
name: pam-app
version: VERSION
summary: Digital signage app
description: Digital signage app
base: core18
confinement: strict
grade: devel
compression: lzo

apps:
  pam-app:
    daemon: simple
    stop-timeout: 1m
    extensions: [gnome-3-28]
    restart-condition: always
    command: snap/command-chain/desktop-launch xwayland-kiosk-launch $SNAP/usr/bin/electron-launcher
    plugs:
      - network
      - network-bind
      - opengl
      - wayland

layout:
  /usr/share/fonts:
    bind: $SNAP/usr/share/fonts

environment:
  XWAYLAND_FULLSCREEN_WINDOW_HINT: window_role="browser-window"

parts:
  pam-app-source:
    plugin: nil
    source: out
    override-build: |
      mkdir -p $SNAPCRAFT_PART_INSTALL/pam
      cp -R PAMApp-linux-x64/* $SNAPCRAFT_PART_INSTALL/pam
    stage-packages:
      - libnspr4
      - libasound2
      - libgconf-2-4
      - libnss3
      - libx11-xcb1
      - libxss1
      - libxtst6

  xwayland-kiosk-helper:
    plugin: cmake
    source: https://github.com/MirServer/xwayland-kiosk-helper.git
    build-packages: [build-essential]
    stage-packages: [xwayland, i3, libegl1-mesa, libgl1-mesa-glx]

  electron-launcher:
    plugin: dump
    source: snap-electron-launcher/
    organize:
      electron-launcher.sh: usr/bin/electron-launcher

Hi @zhex900, xwayland-kiosk-helper has not been the recommended approach for X11 applications for some years now. (It was last updated in 2019 and has been archived.)

So you’re very much on your own in working out what changed. You could start with unsquashfsing the working and non-working snaps and doing a diff.

Alternatively, the recommended approach for Electron applications is here:

(Which doesn’t need Xwayland at all)

Or if you need X11

HTH

1 Like