I tried installing the Docker Integration plugin in IntelliJ

Description

Looking at the manual as to whether Docker can be handled directly from IntelliJ, there is, after all, IDEA.

It seems that ** Docker Integration Plugin ** is installed and used in IntelliJ. So I decided to put it in.

Premise

The environment I am checking is the following Windows machine. I'll try it on my Mac later.

image

image

procedure

1. Installation

1.1. Plugin installation screen

image

Select "File"-"Settings"-"Plugins" from the IntellJ menu.

1.2. Find & Install Docker Integration Plugin

image

Once you've found the Docker Integration plugin, click the install button to install it.

1.3. Restart IntelliJ

image

Restart IntelliJ.

2. Settings

2.1. Expose Daemon on TCP without TLS image

The default setting for TCP connection with the Docker daemon is TLS, so change it from the Docker settings screen to no TLC.

2.2. Check Docker settings in IntelliJ

image

You can see that ** Docker ** has been added under Build, Execution, Deployment on the IntelliJ settings screen. Select Docker.

2.3. Add Docker configuration

image

Leave the Docker configuration as is.

Choices value
Connect to Docker daemon with TCP socket
Engine API URL tcp://localhost:2375
Certificates folder Blank

2.4. Connecting to a Docker host

image

Select Connect from the IntelliJ Docker view.

image

If the connection is successful, you will see a list of images managed by Docker.

3. Setting up the connection to the registry

3.1. Adding the registry

image

From the IntelliJ settings menu, select Registry under Docker and add the configuration.

3.2. Setting registry information

image

Enter the information for the Docker registry to connect to. By default, you can choose between ** Docker Hub ** and ** quai.io ** addresses.

4. Pull Docker image

4.1. Docker image to pull

image

Try pulling the Tomcat image (Tomcat 8.5.23) published on Docker Hub.

4.2. Pull from IntelliJ

image

Right-click in the IntelliJ Docker view and select Pull Image ...

4.3. Specifying the registry

image

The user-authenticated Docker Hub set in 3 is used when registering (pushing) the image.

4.4. Specifying the image

image Specify the image you want to pull and its tag, and click OK.

5. Start the Docker container

5.1. Displaying the Docker container creation menu

image

Right-click on the IntelliJ Docker view and select Create container.

5.2. Starting the container

image Specify the container name.

image If necessary, you can make additional settings for the container such as port binding. After configuration, click Run to start the container.

5.3. Confirmation of container startup

image

Access port 8888 in your host environment. You can see that Tomcat is running.

Summary

You can now manage Docker on IntelliJ. To deploy an application to an application server container such as Tomcat, it seems possible to mount the application built using Docker's volume function.

Recommended Posts

I tried installing the Docker Integration plugin in IntelliJ
I tried the AutoValue library in Intellij
I tried the Docker tutorial!
I tried the new era in Java
I tried running the Angular sample in Auth0 Quick Start with Docker
I tried using Docker for the first time
I tried to organize the session in Rails
I tried touching Docker for the first time
I tried installing docker on an EC2 instance
I tried using the profiler of IntelliJ IDEA
I tried to organize the cases used in programming
I tried to summarize the state transition of docker
I tried the new feature profiler of IntelliJ IDEA 2019.2.
[WIP] I tried the configuration of Docker + Streama + NFS
I tried to implement the Euclidean algorithm in Java
Install the plugin in Eclipse
I tried the VueJS tutorial!
I tried the FizzBuzz problem
I tried BIND with Docker
I tried metaprogramming in Java
I tried installing Ruby on Rails related plugin with vim-plug
I tried to build the environment little by little using docker
I tried to build the environment of WSL2 + Docker + VSCode
I tried to summarize the words that I often see in docker-compose.yml
I tried to illuminate the Christmas tree in a life game
I tried to sort the data in descending order, ascending order / Rails
Use the Findbugs plugin in Eclipse
I tried to explain the method
I tried putting Domino11 in CentOS7
I tried the Java framework "Quarkus"
[Rails] I tried deleting the application
Hit the Docker API in Rust
I tried using JWT in Java
I tried installing CentOS 8 on ESXi 6.7
I was in trouble at work, so I made a plugin for IntelliJ
I tried to build a Firebase application development environment with Docker in 2020
I tried to solve the tribonacci sequence problem in Ruby, with recursion.
I tried to make full use of the CPU core in Ruby
[Ruby] I tried to summarize the methods that frequently appear in paiza
[Ruby] I tried to summarize the methods that frequently appear in paiza ②
I had to lower the PHP version in Docker + Composer + Laravel environment
I tried migrating the portfolio created on Vagrant to the Docker development environment
I tried using Elasticsearch API in Java
I tried a calendar problem in Ruby
I tried to summarize the methods used
I tried running Docker on Windows Server 2019
I tried to implement the Iterator pattern
I made a plugin for IntelliJ IDEA
Microservices 101-I tried putting Docker on Ubuntu-
I tried to summarize the Stream API
What is Docker? I tried to summarize
I tried embedding a formula in Javadoc
About Stream Debugger in IntelliJ IDEA plugin
I tried to solve the tribonatch sequence problem in Ruby (time limit 10 minutes)
About the case where "Docker" freeter tried to put Docker in the existing Rails application
I tried to verify AdoptOpenJDK 11 (11.0.2) with Docker image
How to check the logs in the Docker container
I tried to implement polymorphic related in Nogizaka.
[Rails] I tried to raise the Rails version from 5.0 to 5.2
I tried to implement deep learning in Java
[API] I tried using the zip code search API