Monday, May 8, 2017

how to connect to internal company resource from virtual box on direct access

Issue:
no connection from Virtual box that was provisioned using vagrant to company internal resources while connected there using Direct access.


Solution:
1. Connect to company with DA.
2. Ssh to known linux box inside company with local port forward:


3. Connect to your vagrant box with remote port forward:

 
ssh ubuntu@127.0.0.1 -p 2222 -R 10000:localhost:125 -o LogLevel=ERROR -o IdentitiesOnly=yes -o StrictHostKeyChecking=no -i C:\Jarek\vagrant_hosts\ubuntu_postfix2\.vagrant\machines\default\virtualbox\private_key