IntelliJ IDEA
IntelliJ IDEA – the Leading Java and Kotlin IDE, by JetBrains
Docker and Kubernetes Updates in IntelliJ IDEA 2020.2
IntelliJ IDEA 2020.2 introduces new Docker and Kubernetes features that simplify day-to-day work and offer more flexibility with customization. Let’s have a more in-depth look at the updates in this release.
Docker
Use Selenoid for cross-browser testing of web applications
Selenoid (available only in IntelliJ IDEA Ultimate) is an implementation of the Selenium hub for Docker, which allows you to execute automated tests on web browsers running in Docker containers. For each test, Selenoid creates a container with the specified web browser, environment, and settings.
With IntelliJ IDEA 2020.2 and the Selenium plugin, you don’t need to manually run Selenoid from the command line. You can now select the browsers.json file and click the Launch action in the editor. The IDE will automatically pull all the required containers with the browsers, and run the main Selenoid container to manage them. There are additional options available in the Selenoid run configuration settings, such as output destination folders for logs and videos.
Connect to Docker on Windows with TLS
Previously, to connect to Docker, you had to expose a non-TLS connection in the Docker preferences. In IntelliJ IDEA 2020.2, you can connect to Docker securely with TLS without performing any additional actions.
Kubernetes (IntelliJ IDEA Ultimate)
Add custom configuration files for a cluster connection
We continue to add ways to customize the Kubernetes tools to your needs. This time, we’ve made it possible to add your own kubeconfig
files to configure access to a cluster.
To do this, click the Show Settings button in the Services tool window when selecting a kubernetes root item. Alternatively, go to Preferences / Settings | Build, Execution, Deployment | Kubernetes. Before you apply the settings, you can choose whether to set this path only for the current project or to let the IDE use it globally.
IntelliJ IDEA starts using the newly configured file automatically. However, if you have made configuration changes, you need to click the new Refresh Configuration button in the Services tool window to apply them.
Switch contexts for more efficient work with multiple clusters
A context is a group of access parameters such as cluster, user, and namespace. When you deal with multiple clusters, you’ll want quick access to contexts. Starting from IntelliJ IDEA 2020.2, you can switch contexts quickly with the Context button in the Services tool window.
View Custom Resource Definitions (CRDs) in a cluster
In IntelliJ IDEA 2020, you can view a list of all the existing custom schemas and resources created on a cluster. Here’s the new feature in action.
In the previous release, we introduced the ability to apply CRDs and other resource files using the Apply icon in the gutter. The applied CRD is then shown inside the Custom Resources item in the Services tool window tree.
To work with сustom resources in the IDE editor, you need to add a path to your CRD via Preferences / Settings | Languages & frameworks | Kubernetes.
Get full support for ConfigMaps and Secrets
IntelliJ IDEA fully supports the Kubernetes ConfigMaps and Secrets API objects. Complete with editor completion, resolve, rename, and find usages. Now the information for these options is not only taken from your project but also the configured cluster.
If you call completion for ConfigMap names and keys, the IDE will offer suggestions. The items from the cluster are marked in blue, all others are only present in the current project.
It is now possible to call Find Usages from the cluster for ConfigMaps/Secrets and their keys. Select the corresponding item in the Services tool window and call Find Usages in the context menu.
Now you can navigate from the ConfigMap/Secret usages to their declarations in the project and cluster.
Another useful time-saving update is the possibility to rename ConfigMaps/Secrets and their keys. When you rename these API objects, the IDE will apply the changes to wherever you have referenced them. This feature is available for sources only.
Please feel free to share your feedback on the current updates on Twitter or in our issue tracker.
We hope you are excited about our brand-new features to help you with your daily work with Kubernetes and Docker. Stay tuned for more improvements!
Happy developing!