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

cockpit-client: cannot download files in cockpit-files #21413

Open
jelly opened this issue Dec 9, 2024 · 2 comments
Open

cockpit-client: cannot download files in cockpit-files #21413

jelly opened this issue Dec 9, 2024 · 2 comments

Comments

@jelly
Copy link
Member

jelly commented Dec 9, 2024

Trying to use cockpit-client to browse my nas and download files fails without an error. Resulting in no files being downloaded.

This makes sense as the flatpak has no filesystem access by default so it doesn't work out of the box, trying to give it access to xdg-download or the whole $HOME dir with flatseal downloading does nothing.

The web browser console doesn't report any errors nor is it clear if the download button triggered any JavaScript.

@jelly
Copy link
Member Author

jelly commented Dec 9, 2024

The issue here can be that we implement downloading with window.open which works in a normal desktop, but as this is a flatpak it can't spawn a new window likely.

Even better would be if we could implement a portal for saving files, we don't support downloading multiple files. anyway.

Furthermore cockpit-client would not be able to show the progress of the downloaded file even if it worked, so that needs some more thought as well.

@jelly
Copy link
Member Author

jelly commented Dec 9, 2024

The issue is easily reproducible without a flatpak:

./bots/vm-run -s cockpit.socket fedora-40
./src/client/cockpit-client --external-ws http://127.0.0.2:9091

Then try to download anything. I recall we explicitly use window.open because of browser handling of failed downloads which Firefox or Chrome doesn't handle well.

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