skypilot
skypilot copied to clipboard
Ability to run SkyPilot Tasks locally
Using SkyPilot requires access to one or more supported cloud providers. This is a big barrier to entry for users who don't currently have access to clouds, those who work with other clouds or are just curious about SkyPilot.
It would be nice to have a local mode[^1] which allows users to run SkyPilot tasks on their local machine. #968 provides a prototype of this vision - it creates a ssh-able docker container to serve as a VM that SkyPilot on-prem can connect to. We should look into having the proposed sky local up/down
CLI as a native feature.
Naturally, there are lots of design/engineering choices to be made:
- Interface - Do we want to expose the notion of a cluster when launching locally? If so, can we have something better than
sky local up/down
to manage the local cluster? - Storage - rsync file mounts should work, but should we prohibit S3/GCS mounting?
- Accelerators - we need a pipeline in the #968 code to support local GPUs (docker-compose should use
nvidia-docker
runtime) -
num_nodes
- We can support simulating multi-node local clusters (by creating multiple local containers), but maybe good to start with single node - We need support for specifying SSH port number in Sky onprem.
[^1]: LocalDockerBackend
aimed to achieve this, but does not have feature parity with the ray backend.
I brought #968 up to date with master here! I squashed everything into one commit (but I can restore the history if you prefer).
What would be a good next step?
Awesome work @ewzeng! We should now look at how we can move some of the local
directory's components to either our code or to ~/.sky/
. There are a few things I anticipate doing here:
- We should move the container creation and deletion logic from
local/setup.sh
andlocal/cleanup.sh
tocli.local_up
andcli.local_down
(perhaps define some methods in backend_utils.py and call subprocess.run() there to replicate the shell scripts?). - Instead of using the ssh key hardcoded in
local/.env
, we should look at using~/.ssh/sky-key
for SSH authentication to the container - Add a method to automatically build the container image (and its base image) if they are not present, and add invoke it
in
cli.local_up()
There might be more things to do. The idea is to make sky local up
and sky local down
work generally on any user's laptop which has sky and docker installed.
Sounds good! I will start working on this.
Perfect @ewzeng. It is good to get Sky On-prem and local mode working in tandem (i.e. local mode using Sky onprem as backend).
This issue is stale because it has been open 120 days with no activity. Remove stale label or comment or this will be closed in 10 days.
This issue was closed because it has been stalled for 10 days with no activity.
This is now supported with sky local up
.