eclipse-che/che

Bring my own IDE: How could i do some task from my ide ?

Opened this issue · 7 comments

Summary

Hi,
For some time, I've been using my eclipse Che instance with my own IDE (IDEA or VsCode, for the case where I have my own computer on me). I had a case where I wanted to stop/restart from local devfile and ended up unable to do so. Is there a way to trigger those restart from my own IDEA (or vscode) installed on my computer ? If so, does creating a Task File to make those automatic seems a good idea ? I also started translating my command into idea's own command so it could be a solution.

Relevant information

No response

I had a case where I wanted to stop/restart from local devfile and ended up unable to do so.

About VS Code
Do you mean these commands:

image

please provide steps to reproduce if they don't work for your case.

Is there a way to trigger those restart from my own IDEA (or vscode) installed on my computer ?

it's possible to run these actions from the dashboard - does it work for your case?

Also you can take a look what Stop Workspace does under the hood here using k8s service.
Restart Workspace first stops a workspace and then start it on the browser side.

About IDEA - maybe @azatsarynnyy could help you...

I had a case where I wanted to stop/restart from local devfile and ended up unable to do so.

About VS Code Do you mean these commands:

Yes those one, and yeah it works for me. The full online work perfectly for me (and it saved my life a lot of time 🤣 )

Is there a way to trigger those restart from my own IDEA (or vscode) installed on my computer ?

it's possible to run these actions from the dashboard - does it work for your case?

For the basic one yeah, but the one where I need for example a restart from local devfile (because I need to update my image for example) I didn't find it on the dashboard.

Also you can take a look what Stop Workspace does under the hood here using k8s service. Restart Workspace first stops a workspace and then start it on the browser side.

Thanks for the link, I will search how it works and start to work on a possible integration 👍

Just so you understand, I want to keep the ability to handle my workspace like with the full online vscode with hybrid case (https://github.com/che-incubator/che-idea-dev-server or directly connecting my VS Code with the Kubernetes extension to the pod). And I'm thinking if it's easy to make a tiny CLI to do the basics that I will embed in my future image.

I need for example a restart from local devfile (because I need to update my image for example) I didn't find it on the dashboard.

you are right - restart from local devfile action is absent on the dashboard...

I want to keep the ability to handle my workspace like with the full online vscode with hybrid case (https://github.com/che-incubator/che-idea-dev-server or directly connecting my VS Code with the Kubernetes extension to the pod)

probably you are looking for something like: #22706

I need for example a restart from local devfile (because I need to update my image for example) I didn't find it on the dashboard.

you are right - restart from local devfile action is absent on the dashboard...

I want to keep the ability to handle my workspace like with the full online vscode with hybrid case (https://github.com/che-incubator/che-idea-dev-server or directly connecting my VS Code with the Kubernetes extension to the pod)

probably you are looking for something like: #22706

Yep, it could for VsCode, and for IDEA (Jetbrains gateway) I would just reproduce it. To direct connect into my pod, I use the “join from vscode” provided in the Kubernetes extension when you right-click a pod. Does the extension force the usage of ssh ?

Hi, I'm back a little more than a month later.
Will working on my CLI to hasten some process, I ended up encountering a problem with how to keep alive my workspace when I hope in with VS Code and that the default IDE is che-code. How can I get the MACHINE_EXEC_PORT, by default it's 3333 ?

The process that I intend to set up:

  1. Start a session with ./dev-cli workspaces open-vs-code {container name} {Other param that may be needed}
  2. [DONE] The CLI start a new VS Code window that will go in the targeted container and folder (default to /projects/ but can be set)
  3. [Need help] Then the CLI don't give back the term and will call every minute the health check endpoint through an in process reverse proxy.

How can I get the MACHINE_EXEC_PORT, by default it's 3333 ?

yes, it's defined here

Thanks, I think I will go with a default value then