Unfortunately, this will keep popping up every time since we’re using the community edition. You won’t be asked this again after the first time since the container will have access to this state information afterwards. If you follow those 4 simple steps above (oh, I mean, 1 simple command) then you will see something like this. Running the Docker Setup Script | Show me IntelliJ I don’t want to paste it here because it will grow out of sync over time – I update them to make them better and also get good feedback from readers. I encourage you to take a look at the run.sh script and Dockerfile on MVP Java´s GitHub. By default your Maven $HOME/.m2 artifact directory is shared with the container so you don’t have to download the internet. So if you download a plugin, it will be there the next time. This directory and others will be created for you in order for the state of IntelliJ to persist on your host (through bind volume mounts). Just place you source code in (default location) $/IdeaIC2020.3/IdeaProjects You can share your source code that is on your host machine with the docker container. It can be very frustrating when you exit the container and find your source code on the host is now owned by root! The run.sh script will detect which $USER is executing the script and create that user in the container so you don´t get those permission issues. This IntelliJ Docker image has been setup to preserve the IDE state as well as allow you to perform your Java development as the $USER you actually are, not root. We don’t want to lose them every time we re-run our container! That would be very frustrating. We all have our own custom developer preferences, settings, plugins, theme etc. be-quiet! Preserving Your IntelliJ Developer Environment Preferences I’m going to show you how to get setup using the docker images I’ve developed for Linux hosts which are available on my DockerHub account and the setup script run.sh and Dockerfile are available on my GitHub account.Īll you need is 1 command after git cloning the following on the Linux command line. I’m not going to go into the pros of running your IDE in a docker container since I have pounded on those points over and over again in the previous articles (see above). Alright, alright, here it is and here we go! That was better but still the people chanted “ We want IntelliJ!“. Well the landscape has changed quite a bit but I got a lot of slack from readers complaining … “ Why Netbeans“? I went back to the drawing board and then came out with another docker image for Java development using eclipse and the Spring STS plugin – Running Spring Tool Suite 4 in Docker. I wrote an article way back in 2017 Running NetBeans for your Java Development Environment … remember NetBeans?! Let’s take that to the next level and get you setup with Docker for your Java development environment with IntelliJ – community edition 2020.3 Today’s favorite IDE is IntelliJ, taking anywhere between 60-80% of the developer base. Java developers have spoken and voted through developer surveys. Running IntelliJ IDEA in Docker Container Views: 5,055 Reading Time: 4 minutes Tired of setting up your Java Development Environment over and over again for different machines, environments or platforms? Me too! That’s why I now run my Java Developer Environments inside a Docker Container.
0 Comments
Leave a Reply. |