TripleParity/docks-api

Content Type Header not forwarded to Docker API

Closed this issue · 3 comments

Message

{"message":"Content-Type specified () must be 'application/json'"}

Steps to reproduce

sudo docker run --rm -it -p 8080:8080 -v /var/run/docker.sock:/var/run/docker.sock tripleparity/docks-api:develop

curl --header "Content-Type: application/json" --request POST --data '{"name": "mahHeart"}' http://localhost:8080/docker/volumes/create

> {"message":"Content-Type specified () must be 'application/json'"}

Expected

sudo curl --unix-socket /var/run/docker.sock --header "Content-Type: application/json" --request POST --data '{"name": "mahSoul"}' http:/api/volumes/create

> {"CreatedAt":"2018-05-08T11:13:31+02:00","Driver":"local","Labels":null,"Mountpoint":"/var/lib/docker/volumes/shet/_data","Name":"mahSoul","Options":null,"Scope":"local"}

@devosray can you please look into this since you set up the initial proxy?

Closed by #35