---
# System prepended metadata

title: "docker remote host \U0001F40B"
tags: [docker]

---

###### tags: `docker`

# docker remote host 🐋
https://code.visualstudio.com/docs/remote/containers-advanced#_developing-inside-a-container-on-a-remote-docker-host

[Connect to remote Docker over SSH](https://code.visualstudio.com/docs/containers/ssh)
Go to Setup SSH Tunneling 


## docker context

```bash=
docker context create 192.168.1.179 --docker "host=ssh://paul@192.168.1.179"
docker context list
docker context rm 192.168.1.179
docker context use 192.198.1.179
docker info
```

### test 

```bash=
docker run -it -p 5000:5000 -e PORT=5000 --name node-app paulyk/backend
```

### enable user on linux instance

```bash=
adduser paul
usermod -aG docker paul
cp -r .ssh /home/paul
chown -R paul: /home/paul/.ssh

echo 'connect to host'
export DOCKER_HOST=ssh://paul@192.168.1.179
docker info
```