Hi All,
I am new to these forums, so apologies if this information is out there already.
I just setup ohdsi-in-a-box (via VM, not AWS), I was wondering if anyone has experience or instructions on how I can expose the postgresql database(s) to my host machine, or even better, my local wifi network?
cheers,
Calum
I figured it out myself, it was not too bad. Here are the instructions for anyone else trying…
- Before launching the VM, click settings, then the ‘Network’ tab. Switch from NAT to Bridged Adapter
- Launch the VM
- Make sure openssh is installed/enabled
sudo apt-get install openssh-server
- Check you see tcp connection in port 22 for ssh
netstat -lnpt | grep 22
- Check you can ssh into the VM from within the VM with
ssh 127.0.0.1
- Allow incoming traffic
iptables -A INPUT -p tcp --dport ssh -j ACCEPT
- Get the IP address of the VM now via
ip addr show
(will be the first non 127.0.0.1 ip you see)
- ssh from an external machine ssh ohdsi@
- connect to postgresql via
postgresql://ohdsi:<passworrd>@<VM IP>:5432/ohds
Now I can connect to the VM/VirtualBox from any computer in my local network and access the databases however I like
cheers,
Calum