Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ChromeBook Support #333

Closed
tresf opened this issue Jun 8, 2018 · 3 comments
Closed

ChromeBook Support #333

tresf opened this issue Jun 8, 2018 · 3 comments

Comments

@tresf
Copy link
Contributor

tresf commented Jun 8, 2018

Objective

Document Google ChromeBook support for QZ Tray

Summary

  • βœ… QZ Tray is technically installable on ChromeOS through Crostini
  • 🚫 Configuring printers from Crostini is challenging
  • 🚫 Chrome requires a security exception for https://localhost:8181
  • 🚫 QZ Tray's user interface is not accessible
  • βŒ› This experience may improve with time.

What Works

  • Basic connectivity through chromium browser installed inside Crostini.

  • Basic connectivity through native Chrome after adding security exception to https://localhost:8181

    # first, install crostini
    
    # second, install chromium, but in crostini
    sudo apt-get install chromium
    
    # open chromium
    # opening it to any page once will build the certdb file needed for https.
    chromium about:blank
    
    # snag and install the latest QZ Tray version
    wget -qO - qz.sh | bash 
    
    # close and relaunch chromium
    pkill -9 chromium && chromium https://demo.qz.io

    image

    • Warning, at the time of writing this, Crostini running Chromium is a bit unstable. Some actions (such as right-clicking the bookmarks bar) will crash out the container's UI and any terminal windows you have open. (crash fixed with ChromeOS 70) Use with caution.

What Doesn't Work

  • Native Printer Listing
  • Native ChromeOS Chrome Browser
    • Since the Java instance runs inside a sandbox container under an RFC6598 IP scheme (e.g. 100.115.92.198) localhost connections won't work, but container IP will work if overridden using qz.websocket.connect({host: '<RFC6598 ADDRESS>'}.
    • Since the Java sandbox cannot install HTTPS certificates to the native store for ChromeOS, HTTPS will ultimately fail unless running a browser installed from terminal. A manual exception can be added to the native browser on a per-user basis if combined with IP scheme workaround.
  • System Tray icon will not display, making it impossible to access About Dialog, Certificates, Log Window, Auto-start Settings.
  • HID/USB
    • Attempts to use USB/HID will throw some Native Library errors org.usb4java.LoaderException: Native library not found in classpath: /org/usb4java/linux-aarch64/libusb4java.so or Unable to load library 'hidapi': Native library (linux-aarch64/libhidapi.so) respectively. This appears to be due to usb4java and hidapi not yet providing newer ARM linux-aarch64 packages. Forcing the linux-arm packages will cause errors such as wrong ELF class: ELFCLASS32 (Possible cause: architecture word width mismatch).
    • HID will technically work if every instance of SystemUtilities.isWindows() is replaced with true in PrintSocketClient.java. This will force QZ Tray to utilize PureJavaHIDAPI on Linux. Unfortunately, USB device pass-through for the LXD containers needs to be supported in Crostini first. At the time of writing this, the ETA from upstream is late 2018.
@tresf
Copy link
Contributor Author

tresf commented Sep 27, 2018

Google has announced that Chrome OS's Linux support is finally out of beta, so these test results need to be redone with an updated Chromebook.

Updated to latest. Less crashes but overall status is about the same.

@tresf
Copy link
Contributor Author

tresf commented Mar 7, 2019

It's been over a year and core features requiring this still don't work inside Crostini such as USB, printers as well as no way to control the port forwarding or HTTPS.

Closing this for now. We'll revisit it when Crostini has better support.

@tresf tresf closed this as completed Mar 7, 2019
@tresf
Copy link
Contributor Author

tresf commented Apr 25, 2023

Some things are improving.

  • QZ Tray now comes bundled with Java, so the following command will install QZ Tray rather seamlessly (this was even tested on an ARM-based Chromebook).

    From Terminal:

    curl qz.io | bash
  • QZ Tray has no problems loading USB/HID and Serial ports now.

  • Crostini now -- by default -- forwards port 8181/8182, which QZ Tray uses for communication.

Some things that still are lacking:

  • QZ Tray's "menu" system is broken on ChromeOS. This should be drastically improved once "kiosk" support is merged: Show GUI from Kiosk ModeΒ #1043. I'd be happy to provide an experimental build with this feature.
  • Connections to localhost:8181 won't succeed unless a security exception is added for https://localhost:8181/. I don't think there will ever be a way to fix this (strict security sandboxing), but it would be trivial to add instructions to users for this security exception.
  • There's still no straightforward way of adding printers. Printers added in Settings won't be reachable by QZ. The CUPS web interface from within the Crostini VM is a viable alternative, but setting up printers this way is not easy or intuitive.
  • QZ Tray does not automatically start, it must be launched manually via /opt/qz-tray/qz-tray

If any of the above can be improved upon, please reply here or on our mailing list.

@tresf tresf closed this as not planned Won't fix, can't repro, duplicate, stale Apr 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant