I'm attempting to run the following command on Mac OSX:
docker run --rm --name kong-database \
--network=kong-net \
-v /Volumes/docker/postgres:/var/lib/postgresql/data \
-p 5432:5432 \
-e "POSTGRES_USER=kong" \
-e "POSTGRES_DB=kong" \
postgres:9.6
With the intention that it will launch postgres in in a docker container, and persist the database data on my local file system in /Volumes/docker/postgres. However, I get the following error, and the container fails to run:
chown: changing ownership of '/var/lib/postgresql/data': Operation not permitted
Any idea what I can do to get this going?