could not link file “pg_xlog/xlogtemp.20” to “pg_xlog/000000010000000000000001” (initialization of log file): Operation not permitted

I am doing a Docker training session and the container uses PostgreSQL for database needs. On doing docker-compose up, i got the error in the title. postgres_1 | postgres_1 | Data page checksums are disabled. postgres_1 | postgres_1 | fixing permissions on existing directory /var/lib/postgresql/data … ok postgres_1 | creating subdirectories … ok postgres_1 | […]