Skip to content

Conversation

fioan89
Copy link
Collaborator

@fioan89 fioan89 commented Sep 29, 2025

It will be used later by the Coder Settings view to allow users to enable or disable SSH hostname wildcard configuration.

It will be used later by the Coder Settings view to allow users
to enable or disable SSH hostname wildcard configuration.
Updated the UI component to allow configuration by the user
when generating the ssh config for Coder Gateway.
Up until now we just checked if the Coder deployment supports
this feature, but now users have to option to continue to
use expanded hostnames in the ssh config.
Copy link
Contributor

github-actions bot commented Sep 29, 2025

Qodana Community for JVM

34 new problems were found

Inspection name Severity Problems
Usage of API marked for removal 🔴 Failure 13
Local 'var' is never modified and can be declared as 'val' 🔶 Warning 1
Incorrect string capitalization 🔶 Warning 1
Constant conditions 🔶 Warning 1
Usage of redundant or deprecated syntax or deprecated symbols 🔶 Warning 1
Throwable not thrown 🔶 Warning 1
Redundant nullable return type 🔶 Warning 1
Unused symbol 🔶 Warning 1
Convert 'object' to 'data object' ◽️ Notice 5
Class member can have 'private' visibility ◽️ Notice 3
String concatenation that can be converted to string template ◽️ Notice 2
Argument could be converted to 'Set' to improve performance ◽️ Notice 1
@Deprecated annotation without 'replaceWith' argument ◽️ Notice 1
Return or assignment can be lifted out ◽️ Notice 1
Redundant lambda arrow ◽️ Notice 1

💡 Qodana analysis was run in the pull request mode: only the changed files were checked

View the detailed Qodana report

To be able to view the detailed Qodana report, you can either:

  1. Register at Qodana Cloud and configure the action
  2. Use GitHub Code Scanning with Qodana
  3. Host Qodana report at GitHub Pages
  4. Inspect and use qodana.sarif.json (see the Qodana SARIF format for details)

To get *.log files or any other Qodana artifacts, run the action with upload-result option set to true,
so that the action will upload the files as the job artifacts:

      - name: 'Qodana Scan'
        uses: JetBrains/qodana-action@v2023.3.2
        with:
          upload-result: true
Contact Qodana team

Contact us at qodana-support@jetbrains.com

CLIManager can be created with default settings (simplifies testing),
among which the ssh wildcard config is enabled. But in reality the
config can be disabled by the user.
…rd config was changed

Currently, if a user starts a connection with wildcard enabled and then later on it disables
the wildcard config then the recent connections becomes unusable because the hostnames are invalid.
The issue can reproduce the other way around as well (start with wildcard ssh config disabled,
start an IDE and then later on enable wildcard config)

This commit addresses the issue by resolving the hostname on demand when the user wants to
open the remote IDE from the recent connections panel.
@fioan89 fioan89 marked this pull request as ready for review September 30, 2025 20:29
Connections started with two different hostnames (because of the ssh wildcard config)
can be rendered twice in the Recent projects panel.
With this commit we ignore the hostname and instead use the workspace name and deployment URL.
Copy link
Member

@code-asher code-asher left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me!

Do we know why users want this? I figured wildcard would always be better.

@fioan89
Copy link
Collaborator Author

fioan89 commented Oct 1, 2025

Looks good to me!

Do we know why users want this? I figured wildcard would always be better.

There is apparently a client that has issues with wildcard config, "After the SSH configuration changes introduced with jetbrains-coder in Version 2.18 (f39e1f4) we are no longer able to connect JetBrains Gateway to our workspaces (Failed to retrieve IDEs / Host is unknown)."

They requested a way to disable the wildcard configuration. Probably it makes more sense to understand the issue they have with this configuration but unfortunately they haven't provided any logs. And on the other hand, Coder Toolbox already provides both options (wildcard enabled or disabled)

@fioan89 fioan89 merged commit aab5916 into main Oct 1, 2025
6 checks passed
@fioan89 fioan89 deleted the impl-support-for-disabling-wildcard-config branch October 1, 2025 22:16
@code-asher
Copy link
Member

Ahh gotcha that makes sense!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants