Lightning-AI / pytorch-lightning

Pretrain, finetune ANY AI model of ANY size on multiple GPUs, TPUs with zero code changes.
https://lightning.ai
Apache License 2.0
28.21k stars 3.38k forks source link

Support headless login #14784

Closed MarcSkovMadsen closed 1 year ago

MarcSkovMadsen commented 2 years ago

First check

Bug description

I want to run lightning on a server in the cloud that where I have access to the terminal via a browser (Its part of a Jupyter Hub). I.e. it cannot open a browser. I see no way to login.

Eventually I would like to deploy my lightning app via lightning run app app.py --cloud.

How to reproduce the bug

$ lightning login

Error messages and logs

INFO: login started for lightning.ai, opening https://lightning.ai/sign-in?redirectTo=http%3A%2F%2Flocalhost%3A38151%2Flogin-complete /usr/bin/xdg-open: 869: www-browser: not found /usr/bin/xdg-open: 869: links2: not found /usr/bin/xdg-open: 869: elinks: not found /usr/bin/xdg-open: 869: links: not found /usr/bin/xdg-open: 869: lynx: not found /usr/bin/xdg-open: 869: w3m: not found xdg-open: no method available for opening 'https://lightning.ai/sign-in?redirectTo=http%3A%2F%2Flocalhost%3A38151%2Flogin-complete'

Important info

lightning==2022.9.8

More info

hhsecond commented 2 years ago

Hi @MarcSkovMadsen, it's not documented anywhere and is not a super clean solution but if this is blocking you, a work around is already being discussed at https://github.com/Lightning-AI/lightning/issues/14700

stale[bot] commented 1 year ago

This issue has been automatically marked as stale because it hasn't had any recent activity. This issue will be closed in 7 days if no further activity occurs. Thank you for your contributions, PyTorch Lightning Team!