Since VS Code's Remote (Container) plugin was convenient, I tried to build a development environment on the VM.
I can't install Docker straight on a Windows VM (Hyper V option is disabled on guest OS).
So, I made it possible to use remote desktop with Linux VM and built a development environment.
--Create a VM on Cent OS 7.
(If you build the environment with Cent OS 8 in the following procedure, you can connect with RDP immediately after setup, but after restarting, there was a problem that neither SSH nor RDP could be connected to the VM, so I tried again)
--Ssh connect to the VM and switch to the Root user.
sudo su -
--Refer to the following site and install the RDP package. Connect to a Linux instance in the cloud using RDP on Windows --Qiita
--Create a user for RDP. Add to sudo list as needed.
$ useradd sampleuser $ passwd sampleuser $ usermod -aG wheel sampleuser
-Changed the default look (if you like) from GNOME Classic to GNOME
echo 'DESKTOP="GNOME"' >> /etc/sysconfig/desktop systemctl restart gdm.service
Connect to the VM using the Remote Desktop app.
-Download the rmp file from Official Site and install it with yum
cd ~/path/to/download/ sudo yum install code-1.42.0-1580986751.el7.x86_64.rpm
--Install the Remote (Conteiner) plugin Search for the "Remote (Conteiner)" plugin on VS Code and install it.
--Install Docker by referring to the following site
--Add users to Docker group
$ usermod -aG docker sampleuser
--Click the "+" button in the "Remote Explorer" tab --Select "Open Folder in Container" and select a blank folder --Select and run the "Python 3" container --Launches a container that can execute Python 3 code
--Git fetch once at the terminal of the container --Once you answer yes to the question of whether to connect to the host, it will be cured.