Private registry with basic auth

Anyone suggest to setup a private registry with basic authentication to push images and allowed to pull from all?

I have tried few tools but mostly not working properly.

There is a tutorial on digitalocean for setting it up on Ubuntu 14.04 that includes a section on setting up basic auth. I am not sure what OS you are using, but hopefully that gets you pointed in the right direction.