I'm trying to run postgresql in docker container, but of course I need to have my database data to be persistent, so I'm trying to use data only container which expose volume to store database at this place.

So, my data container has such Dockerfile:

```
FROM ubuntu

# Create data directory
RUN mkdir -p /data/postgresql

# Create /data volume
VOLUME /data/postgresql

```

Which I run:

```
docker run --name postgresql_data lyapun/postgresql_data true

```

In my postgresql.conf I set:

```
data_directory = '/data/postgresql'

```

Then I run my postgresql container in such way:

```
docker run -d --name postgre --volumes-from postgresql_data lyapun/postgresql

```

And I got:

```
2014-07-04 07:45:57 GMT FATAL:  data directory "/data/postgresql" has wrong ownership
2014-07-04 07:45:57 GMT HINT:  The server must be started by the user that owns the data directory.

```

How to deal with this issue? I googled a lot to find some information about using postgresql with docker volumes, but I didn't found anything.

Thanks!