
By default, the [`new` command](/docs/cli-new) assumes that the image you
give it is stored in a public Docker repository. As an alternative, you can run
a Docker registry on exe.dev, and use that registry to store other images
for your VMs.

First, create a VM:

```
$ssh exe.dev new --name private-registry-test
```

Then, run the a Docker container that runs the Docker registry on it:

```
$ssh private-registry-test.exe.xyz docker run -d --name registry -p 8000:5000 registry:2
```

Then, on the registry machine (or elsewhere), build the image:

```
$ cat > Dockerfile <<EOF
FROM alpine:latest
RUN echo exe.dev > /hello.txt
EOF

$ docker build -t localhost:8000/my-image:v1
$ docker push localhost:8000/my-image:v1
```

Finally, create a new VM, <b>using the VM hostname as the registry host</b>.

```
$ssh exe.dev new --image private-registry-test.exe.xyz/my-image:v1
Creating oboe-hydra using image my-image:v1...
```

And observe it working:

```
$ssh oboe-hydra.exe.xyz cat /hello.txt
built-it
```

Reach out to us via [support](/docs/getting-help) if you're looking to integrate
with a different registry.
