You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Refactor CLI manager to support multiple deployments
Currently multiple deployments will delete each other's binaries so this
uses a directory for each deployment host to store the binaries.
Add a catch for download errors; previously they would go unnoticed.
Also refactor the download a little; instead of checking for the file's
existence catch the appropriate error and set the permissions from
Kotlin code rather than spawning chmod.
Remove a chunk of code where we configure the CLI again before moving to
the next step; we already do that when we first connect (plus it is
missing some checks like making sure the CLI has actually been
downloaded and is the right version, etc). This also makes it
unnecessary to globally store the version and CLI path on the model
since we now only do it in one spot.
This is just a first step; in a future PR the config code will all be
extracted out since we will want to configure every time we try to
connect (rather than just in the initial setup step) since otherwise the
recent connections can fail if you have configured a different
deployment in the meantime (and probably reconnections would also fail
if you already have an IDE open) or if you have restarted (since the
binaries are currently in tmp). We will also need to configure
ourselves since `config-ssh` does not support multiple deployments and
we want to add an environment variable via SetEnv.
0 commit comments