Hi guys,
I’m encountering an issue with a custom service I’ve created to launch nextcloud-client on startup. The problem seems to be related to XDG functionality when the client is launched as a service.
Issue:
When nextcloud-client is launched through the service, it’s unable to open web browsers (I’ve tried with Zen browser and Firefox) via XDG. However, when launched from the command line, it works without issues.
My current service configuration:
nextcloud-client = {
Service = {
ExecStart = "${pkgs.nextcloud-client}/bin/nextcloud";
Environment = [ ];
};
};
Additional testing:
I’ve also tried a dummy service to test xdg-open
directly, and it exhibits the same behavior:
open-zen = {
Service = {
ExecStart = "${pkgs.xdg-utils}/bin/xdg-open https://duck.ai";
Environment = [ ];
};
};
Environment:
- I’m using Wayland as my display server.
- The issue only occurs when running as a service, not from CLI.
Questions:
- Do I need to add specific environment variables to my service configuration?
- Are there any Wayland-specific considerations for XDG functionality in services?
- How can I ensure that nextcloud-client (and other XDG-dependent services) can properly interact with the desktop environment when run as a service?
Any insights or solutions would be greatly appreciated. Thanks in advance for your help!