Lev Goncharov

Infrastructure simplifying engineer

View My GitHub Profile

VScode & Vagrant

Date: 2021-10-16

VS code

In our case it’s the best option. The key idea is to use local VS code as editor, but execute tests inside CDE. How to configure:

  1. Install VS code
  2. Install the plugin Remote - SSH
  3. Create your ssh key at the laptop and copy the target VM
  4. Create Ansible roles development environment via Vagrant.
  5. Put vagrant private key to your home directory
  6. Create ssh config for vscode for connection to Vagrant VM
vscode ssh configuration
Host vagrant
  User vagrant
  Hostname localhost
  Port 2222
  StrictHostKeyChecking no
  IdentityFile ~\.ssh\vagrant
  GlobalKnownHostsFile /dev/null
  UserKnownHostsFile /dev/null

WSL

It’s not the case because too many kludges and limitations. I.e. it’s not possible to run docker & molecule inside WSL (because by nature, WSL is like wine)