You will need to do it now by clicking Create
in the WORKSPACES
tab on your Daytona dashboard to import a repository from your Git provider.
JetBrains Gateway Tools and Resources
Daytona’s JetBrains Gateway plugin allows you to connect to your Daytona workspace from JetBrains Gateways; An application purpose-built for cloud-based development environments without needing to download the selected JetBrains IDE which drastically enhances your development experience.
To use Daytona’s extension, you need to meet several requirements. In this guide, we’ll walk you through the essential components: prerequisite checks, installation, connection setup (with two connection options), effective usage, and a clean uninstallation process. By the end of this guide, you will be able to use Daytona’s JetBrains extension with ease.
Prerequisites
Before you can start using Daytona’s JetBrains Gateway Plugin, the following prerequisites are required to use Daytona’s JetBrains extension:
-
Daytona Installation: If you haven’t installed Daytona on your own infrastructure, please follow the installation guide to install Daytona.
-
Daytona Dashboard URL: To complete the setup, you’ll need the URL of your Daytona dashboard, which you can obtain from installation.
-
JetBrains Gateway: You need to have a JetBrains Gateway installed on your local machine. If you haven’t installed JetBrains Gateway, please navigate to the JetBrains Gateway homepage, scroll down on the page, and find the
Download
button to install the JetBrains Gateway version that suits your local hardware condition.
How to install
The installation process is split into two parts. The first is the package installation, and the second part on how you establish the connection between your Daytona installation and JetBrains Gateway. You will have to install the Daytona Gateway Plugin Package.
- Daytona’s JetBrains Plugin Installation: Click on this link Daytona Gateway Plugin Package to download the latest package (if the download didn’t start automatically, navigate to this link to find the latest JetBrains Gateway plugin version: Home page > JetBrains > gateway > latest). The download will start automatically. Remember the location, or directory of where the package is downloaded to, as you will need it later.
-
Select Managing Providers in JetBrains Gateway: Open the JetBrains Gateway application, at the bottom left corner of the welcome screen, click on the settings button. At the dropdown menu after you click on the settings button, select
Managing Providers
. -
Install Plugin from Disk: At the pop-up window
Plugins
(after you click onManaging Providers
), click on the settings button on the top next toInstalled
. At the dropdown menu, click onInstall Plugin from Disk
right below the optionManage Plugin Certificates
. -
Select the Daytona Gateway Plugin Package: After you click on
Install Plugin from Disk
, your default File Explorer will pop up. You will need to locate where the Daytona JetBrains Gateway Plugin Package is to install it on to JetBrains Gateway Client. Find the Daytona Gateway Plugin Package you downloaded (in the pop-up file explorer) earlier to open it. JetBrains Gateway will install the package automatically. -
Finish installation: JetBrains Gateway will navigate you back to the
Plugins
screen. You will see the Daytona Gateway Plugin Package is installed (under the search bar/downloaded
). Click on the blueOK
button at the bottom right to close the plugin window.
After you click on the OK
button, JetBrains will bring you back to the Welcome to JetBrains Gateway
screen. You are now ready to connect to your Daytona workspace.
Establishing a connection
Now you are on the welcome window of JetBrains Gateway where it shows Welcome to JetBrains Gateway
on the top of the window. You will see several options to run IDE Remotely. SSH Connection
, JetBrains Space
, Docker Dev Containers
, and Daytona
.
There are three options you can use to connect to your Daytona workspaces when you are connecting for the first time. This connection will keep your workspaces, profiles and teams in-sync with your Daytona installation. In this section, we will walk you through each one of them.
- Log into your Daytona dashboard and select a workspace
- Visit your Daytona dashboard URL and make sure you are on the
workspaces
tab. - Select one of the workspaces and click on the
𓈓
icon on it. - Under the dropdown menu, select
Open
.
If you don’t have any repositories imported in this workspace
- Configure default code editor
- On Daytona dashboard, click on
Settings
on the left-hand side menu. At the Default Editor section, select one of the JetBrains IDEs you want to work on.
- Click on the
Workspaces
tab and select one of the workspaces. On the right side of the workspace, click on𓈓
and at the dropdown menu, selectOpen
.
- Open Code Editor
-
After you select
Open
, your default code editor will already be selected on the pop-up window with the title Open <your-selected-workspace-id>. Although you can still change it to another JetBrains IDE here (You may choose other options such as Theia or VS Code, but we will need one of the JetBrains IDEs in this guide). Then click on the green buttonOpen
at the bottom right corner of the pop-up window. -
A new pop-up window will show the instructions on how to use Daytona’s JetBrains Gateway Plugin after you click on
Open
, with the title Open workspace in a JetBrains IDE. Since you are reading this guide, you can click on theOpen
at the bottom again to skip the instruction.
- Granting access to your Daytona workspace
-
After clicking on the green button
Open
, your browser will show a pop-up window asking you “<your-daytona-url> wants to open “JetBrains Gateway”.”, chooseOpen "JetBrains Gateway"
to continue. After this step, your JetBrains Gateway application will open. -
Note that a new browser tab will also open, indicating that this workspace has started. When you click on the green button
Open in WebStorm
, it will redirect you to the JetBrains Gateway application (it won’t open the code editor). -
Please be patient as it may take a few minutes to load the workspace. You will see a pop-up window with the title “Trying to connect using the link”. This is expected and don’t click
Cancel
on the pop-up window. This window will close automatically once the connection is established.
- Select
Connect to Daytona
- On JetBrains Gateway’s welcome screen, you should be seeing Daytona with the Daytona logo, and the button
Connect to Daytona
(If you are not seeing it, head to previous section to confirm if all the steps are configured correctly). Click on the buttonConnect to Daytona
to continue.
- Connect via dashboard URL
-
In the next window, you will see a selection field for Profile with
<Create profile>
, aReconnect
button, and on the right side, a small,Add profile
button. Click on theAdd profile
button to continue. -
You will see a pop-up window with two input fields:
Name
andBase Api URL
. In theName
field, you can name your profile as you wish (It is recommended to use your domain name for ease of recognition). In theBase Api URL
field, you will need to enter your Daytona dashboard URL (kept from prerequisites, for examplehttps://your-domain-name
). After you enter the URL, click on the green buttonNew
at the bottom left corner of the pop-up window. -
After clicking on
New
, JetBrains Gateway and Daytona’s connection will be established.
If you wish to connect to Daytona via SSH without the plugin, please follow the steps below:
- Start a workspace
- Visit your Daytona dashboard URL and make sure you are on the
workspaces
tab. - Select one of the workspaces and click on the
𓈓
icon on it. - Under the dropdown menu, select
Start
.
- Find your public key
-
On your local machine, open your terminal and type in the following command to find your public key:
-
This command will return the path of your public key. Copy the path, it might be in the format of
~/.ssh/id_rsa.pub
or~/.ssh/id_ed25519.pub
. Then within the terminal, type in the following command to find your public key: -
This command will return your public key. Copy the whole output including the prefix
ssh-rsa
,ssh-ed25519
, and save it somewhere safe, then continue to the next part.
- Add your public key to Daytona
-
On your Daytona dashboard, click on the
SSH Keys
on the left-hand side menu. At the SSH Keys section, click on theAdd
button. A pop-up window with two input fields and one selection field will show up:- Name: You can name your public key as you wish.
- Public Key: Paste your public key from the previous step here.
-
After you enter the information, click on the green button
Add
at the bottom right corner of the pop-up window.
- Obtain connection information
-
After you added your public key, click on the
Workspaces
tab and select one of the workspaces you would like to connect to. On the right side of the workspace, click on...
and at the dropdown menu, selectStart
and then click on the...
button again, selectConnect via SSH
. -
A pop-up window will open in the browser with the title
Connect to \<your-workspace-name\>
. You will see two tabs with information for you to copy and paste. Select thePublic Key
tab and copy the information under thePublic Key
section, save it somewhere safe. The format would be:
- Copy the whole line and continue to the next part.
- Connect to Daytona via SSH
-
Head back to JetBrains Gateway welcome screen, and click on the
New Connection
button under theSSH Connection
section. A pop-up window with the titleConnect to SSH
will show up.- Username: Enter the <username> from connection string. It is everything after the white space after
ssh
and before the@
symbol. - Host: Enter the <host> from connection string. It is everything after the
@
symbol and before the white space in front of-p
flag. - Port: Enter the <port-number> from connection string. It is everything after the
-p
flag and before the white space in front of-o
flag. - Specify private key: Click on the 📁 folder button at the end of the selection field, it will pop up your native file explorer to your local SSH configuration folder. Select the private key that matches the public key you added to Daytona in the previous step.
- For example, if you enter the value from
~/.ssh/id_rsa.pub
in the previous step, you will need to select the private key~/.ssh/id_rsa
here.
- For example, if you enter the value from
- Username: Enter the <username> from connection string. It is everything after the white space after
-
After you enter all the information, click on the blue button
Check Connection and Continue
at the bottom right corner of the pop-up window. Your JetBrains Gateway will be connected with your Daytona installation from here.
After these steps, your Daytona installation with JetBrains Gateway is established. you will be navigated to Daytona’s configuration screen on JetBrains Gateway, which includes your team name, GitHub username, etc. We will talk about them in the next section.
Features
Now that you have established the connection between your Daytona installation and JetBrains Gateway, you can navigate to Daytona’s configuration screen by clicking on the Connect
button under Daytona on the welcome screen. In this section, we will walk you through the features of Daytona’s JetBrains Gateway Plugin, including how to create, manage, and use your workspace, how to manage team, profile information, and more.
Creating workspaces
Each workspace created on Daytona is isolated in its own environment, even if it is based on the same repository. In the following two sub-sections, we will talk about how to create and manage your workspaces with Daytona in JetBrains Gateway. Workspaces created within the JetBrains Gateway via the Daytona plugin are synced with your Daytona installation.
-
Create a workspace
Within the Daytona configuration screen in JetBrains Gateway (the screen that shows up after you click onConnect to Daytona
on the welcome screen), there are two ways to create a workspace: -
- Create via repository URL: In the input field
or enter a public repository URL
, you can paste in a repository you have access to, be it a public repository or private repository you own. Then click onNew Workspace
to create a workspace.
- Create via repository URL: In the input field
-
- Create via dropdown menu: On the right side of the field
Repository:
, click on the dropdown menu and select a repository, then click onNew Workspace
to create a workspace. Note that it may take a couple of seconds to create and start a workspace until it is loaded, appearing underRecent Workspaces
. If you click on it multiple times while the workspace is creating, or starting, you are accidentally creating multiple workspace with the same repository.
- Create via dropdown menu: On the right side of the field
Managing workspaces
-
Checking workspaces: Workspaces that have been created on your Daytona dashboard will show up on the Daytona configuration screen under the section
Recent workspaces
with their status (whether it is started, created, or stopped). If a workspace has been started, a circle will be lighted up on the left side of the workspace, you can see the workspace withstarted xxx time ago
. -
Pinning a workspace: You can also pin the workspace (by clicking on the pin button) if you have a lot of workspaces being created, and you want to keep them visible on the configuration screen.
-
Opening workspaces: On the Daytona configuration screen, you can click on a workspace’s name that has been created (the ones under
Recent workspace
) to open a workspace, or you can open it by clicking onOpen
(after clicking on the dots). On the next screenChoose an IDE
, choose a JetBrains IDE you need to work on. It will take a couple of seconds to connect to the remote machine and local binary ready to open the workspace in your selected IDE. If you close the window that showsRunning
while it’s getting ready, JetBrains Gateway will stop the remote connection. -
Working in a workspace
-
- Linux terminal: Once you are working on a workspace in an IDE and start a terminal session within the IDE, you can treat it like a Linux terminal (because it is one). You can install software, or use Docker within the terminal.
-
- Debugging: On the top right side of the IDE, you can click on the debug button (on the top right) to debug your code. The debug panel at the bottom will show you the debugging log, the same as how you’d do it locally. If any extension is suggested to install within the IDE, you can also install them on the workspace and they will be persisted.
-
- Live preview link: If you are working on a web application (port forwarding is supported), you can run
npm run dev
(or other commands) to start the local development server. Once the server is up and running, you can either click on the URL that shows up in the terminal to see the application locally (you can only see live change if your application enabled hot module replacement(HMR), if not, you can only see changes after restarting the server).
- Live preview link: If you are working on a web application (port forwarding is supported), you can run
- Stopping workspaces: To stop a workspace, you can click on the dots
...
button and then click onStop
. Once a workspace is stopped, you can always bring it back by clicking on theOpen
button on the dropdown menu(after you click on the dots...
button on one of the workspaces).
- Granting access to organization access: Organization members can always request that an owner approve access to organization resources for Daytona, and organization owners receive notification of pending requests. For further information, check here.
Managing profiles
Different profiles are equivalent to different Daytona installations, which might associated with your organization, or be personal, identifiable by your Daytona URL. profile-related configuration is located next to Profile:
on JetBrains Gateway’s Daytona configuration screen.
-
Checking profiles: Next to the
Profiles:
, click on the dropdown menu and you will see all of your available profiles. Note that workspaces are correlated to your Daytona installation (aka profile), if you switch your profile you won’t see the same workspaces on the previously selected profile. -
Adding a profile:
-
- Click on the
Add profile
button next to theEdit
button. On the pop-up window, you will need to inputName
(being displayed on Daytona’s JetBrains Gateway configuration page, use a domain name for ease of recognition) andBase Api URL
(your Daytona dashboard URL, no subdomain required. For example: if your Daytona dashboard URL ishttps://daytona.com
, the input for this field would bedaytona.com
).
- Click on the
-
- After inputting the information, click on
New
. You will then be redirected to your Daytona dashboard’s signin page to select an identity provider to sign in. Depending on whether you have a session that exists(that you are signed in) with your identity provider, you may be redirected to your identity provider(Github, Gitlab, BitBucket) to sign in.
- After inputting the information, click on
-
- After signing in to your identity provider, you will be asked whether you’d like to grant access to JetBrains, click on
Yes
to continue. Once the profile (an installation) establishes a connection with JetBrains Gateway, you should be able to see your workspaces or create workspaces based on different identity providers associated with that profile.
- After signing in to your identity provider, you will be asked whether you’d like to grant access to JetBrains, click on
-
Editing a profile: On the Daytona configuration screen (after you click on
Connect to Daytona
on JetBrains Gateway’s welcome screen), you can click on the edit button next to profile dropdown menu to edit your profiles. Once you click on it, you will be able to see and edit the name, Base Api URL, Keycloak Realm, Keycloak URL and SSH Port on the pop-up windowEdit. After you finish editing your profile, you can click on
Storeto confirm editing, or cancel the current edit by clicking on
Cancel`. -
Delete a profile: You can click on the edit button on the Daytona configuration screen and then select
Delete
to delete a profile.
Managing teams
At the moment, you can only manage team-related information on your Daytona dashboard. Note that your workspaces are correlated to your team. If you switch to another team (say Team B), you won’t be seeing workspaces created on the previous team(say Team A).
- Switching team: You can see all the teams on the Daytona configuration screen on JetBrains Gateway. Next to the field
Teams:
, click on the dropdown menu to check what team exists with your account, or switch to another team.
Remove Daytona from JetBrains Gateway
-
Open JetBrains Gateway, on the welcome screen, select the setting icon at the bottom left corner and choose
Manage Providers
from the dropdown menu. -
On the plugins screen, you should be able to see
Daytona Gateway
under the search result/downloaded
, click on it. On the right side of the screen, you should see a down arrow button next toDisable
(you can click onDisable
to disable it). Click on the down arrow button and chooseUninstall
from the dropdown menu. -
A pop-up window
Uninstall Plugin
will show up asking you “Are you sure you want to uninstall the plugin ‘Daytona Gateway’?”, selectYes
. After you click onYes
, you will be back to the plugins screen, click on the bottom rightOK
. Then JetBrains Gateway will ask you “Restart JetBrains Gateway to apply changes in plugins?”, click onRestart
to take effect of the uninstallation.