plexora connect
Start Plexora on a remote host, tunnel to it, and open a browser here. Run this on your OWN computer, not on the remote host.
Usage
plexora connect [-h] [--remote-command REMOTE_COMMAND] [--save NAME] [--srun ARGS]
[--bind-node] [--forward [LOCAL:]REMOTE] [-J JUMP] [--ssh-opt KEY=VALUE]
[--port PORT] [--remote-port REMOTE_PORT] [--timeout TIMEOUT]
[--data-dir DATA_DIR] [--plugins PLUGINS] [--no-browser]
[--also-serve KIND:ID=PATH] [--local-serve KIND:ID=PATH] [--install]
[--no-local-node] [--node-name NODE_NAME] [--node-port NODE_PORT]
[--node-allow-origin ORIGIN] [--pair [ORIGIN]]
target [datasource]Arguments
targetrequired[user@]host to ssh into, or the name of a server saved with --save (or in Settings > Remote servers).
datasourceOptional datasource/project name to open directly.
Options
--remote-command REMOTE_COMMANDHow to invoke Plexora on the remote host (default "plexora"). Use this when it is not on a non-interactive PATH. An environment prefix is enough -- "/home/you/miniconda3/envs/plexora" -- or give a full command, e.g. "conda run --no-capture-output -n imaging plexora".
--save NAMERemember this connection under NAME, so next time plexora connect NAME is the whole command. Saved servers are shared with Settings > Remote servers. No password is stored.
--srun ARGSTreat the target as a SLURM login node and run Plexora inside a job, e.g. --srun "-p interactive -t 4:00:00 -c 16 --mem 128G" -- which is what the Settings form fills in.
--bind-nodeWith --srun, forward from the login node instead of ssh-ing into the compute node. For sites that refuse the latter.
--forward [LOCAL:]REMOTErepeatableForward another port from the remote host, e.g. --forward 8642 for a plexora node serve running beside the viewer. Repeat for each. Only needed when your BROWSER has to reach the node directly; the viewer reaches it over there without any of this.
-J, --jump JUMPssh -J jump host to reach the target through.
--ssh-opt KEY=VALUErepeatableExtra ssh -o option; repeatable. Keys, ports and usernames are usually better placed in ~/.ssh/config.
--port PORTLocal port to serve the tunnel on (default: a free one).
--remote-port REMOTE_PORTPort to use on the remote host (default: a free-looking high one).
--timeout TIMEOUTSeconds to wait for Plexora to answer (default 60, or 18000 with --srun, where the job may sit in a queue).
--data-dir DATA_DIRPlexora data directory on the remote host, adopted if that account has not chosen one yet. An account that has is left alone -- otherwise the viewer reads one directory while that account's own commands write to another.
--plugins PLUGINSPlugins to activate on the remote host.
--no-browserSet up the tunnel and print the URL, but do not open a browser.
--also-serve KIND:ID=PATHrepeatableA file on the REMOTE host to serve as a data node beside the viewer, e.g. --also-serve table:cells=/scratch/cells.h5ad. Started, forwarded and registered automatically. Repeat for each.
--local-serve KIND:ID=PATHrepeatableA file on THIS machine to serve to the remote viewer, e.g. --local-serve table:cells=~/study/cells.h5ad. For the layout where the images are on the cluster and the cell table never left your laptop. Repeat for each.
--installInstall or update Plexora on the remote host before launching it: pip install --upgrade plexora, in the environment --remote-command names. Off by default, because it writes to that machine. Saved with --save, and the same switch the Settings form calls "Install or update Plexora".
--no-local-nodeDo not run a data node on this computer. One is started for every connection by default, with nothing to serve until you pick something: it is what lets the viewer's data forms offer files from HERE, which they otherwise cannot reach at all.
--node-name NODE_NAMEWhat to call the data nodes this connection registers. Defaults to the saved server's name, or the remote host's.
--node-port NODE_PORTPort for the remote data node (default: a free-looking high one).
--node-allow-origin ORIGINrepeatableAnother browser origin the data nodes this connection starts should answer, besides this machine's own viewer address. Repeat for each.
--pair [ORIGIN]Also print a link per data node that pairs it with the Plexora page at ORIGIN (default https://viewer.plexoraapp.com), and allow that origin on every node. Put it after the server name.
Examples
Start Plexora on a workstation and open it here
plexora connect [email protected]Open a project straight away
plexora connect [email protected] exemplar-001Plexora is in a conda environment on the remote host
plexora connect [email protected] --remote-command /home/me/miniconda3/envs/plexoraRun inside a SLURM job
plexora connect [email protected] --srun "-p interactive -t 4:00:00 -c 8 --mem 64G"Save the connection, then reuse it by name
plexora connect [email protected] --srun "-p interactive -t 4:00:00" --save hpc
plexora connect hpc