cURL to DropBox using Symfony 3

I use the Gaufrette Bundle of Symfony to access DropBox API.
The code in my controller is

$dropbox = $this->get('acme.dropbox.api');
$dropbox->getAccountInfo();

I get an error
Curl error: (77) error setting certificate verify locations:
CAfile: rootca
CApath: /etc/ssl/certs
500 Internal Server Error – Dropbox_Exception_NotFound

I used Docker so not sure if it’s with the way I configured the certificates on my Docker. I used https://github.com/eko/dockersymfony bundle for Docker.

  • Connecting docker locally with vagrant provisioned docker
  • Docker issue in sharing folder on windows host through VBoxManage command
  • how to assign public IP while run the docker container in linux
  • How to automate Grunt on a Docker image
  • Using boot2docker in OSX
  • Vagrant managed docker container doesn't start
  • How to autoscale Docker container hosts?
  • Load balancing docker swarm using Ha Proxy
  • docker-machine ssh command for mongodump
  • Is Alpine Linux an implementation of a Unikernel?
  • Connecting local cassandra cluster with docker container
  • When I start my app with PM2 + Docker, just run and exit
  • One Solution collect form web for “cURL to DropBox using Symfony 3”

    The problem was it couldn’t find the certificate file.

            curl_setopt($ch, CURLOPT_CAINFO, "/etc/ssl/certs/ca-certificates.crt");
    

    On my docker box the certificates are in folder /etc/ssl/certs and I had to write the file extension as well.

    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.