Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions src/ws/cockpit-desktop.in
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,11 @@ esac

detect_browser

if ! ${2:+ssh "$2"} command -v cockpit-bridge >/dev/null 2>&1; then
echo "cockpit-bridge is not installed${2:+ on $2}" >&2
exit 1
fi
Comment on lines +108 to +111

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, but this sucks a bit when using ssh, no? It makes two connections, with all the overhead of key unlocking, password entry, possible 2FA, etc. Can we perhaps run a shell script on the remote side which handles this more gracefullY?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure, btw we don't have a desktop file for this? Or do we as if we do this is all kinda moot.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The only .desktop file I'm aware of is for sub-man-cockpit, that's shipped in RHEL desktop. Of course without ssh.

Alternatively, only do this check if $ssh is empty? That at least makes it simpler for the local case.


# start the bridge; this needs to run in the normal user session/namespace
coproc ${2:+ssh "$2"} cockpit-bridge
trap "kill $COPROC_PID; wait $COPROC_PID || true" EXIT INT QUIT PIPE
Expand Down
Loading