title: Elastic Beanstalk can't connect DynamoDB
body: <p>I'm really newbie with aws, then sorry if it's a silly question.</p>
  
  <p>I did a website which connects with an online DynamoDB table and it is fully working on my local, but when I deploy the website code in my Elastic Beanstalk environment, it doesn't connect to the DynamoDB table.</p>
  
  <p>Is there some configuration I should have done?</p>
  
  <p>I am afraid nobody else had this problem.</p>
  
  <p>My website have been written in using the aws php sdk by the aws.phar.</p>
  
  <p>I did create a policy for the iam user as follow:</p>
  
  <pre><code>    {
          "Version": "2012-10-17",
          "Statement": [
              {
                  "Action": [
                      "dynamodb:GetItem",
                      "dynamodb:PutItem"
                  ],
                  "Effect": "Allow",
                  "Resource": [DynamoDB table],
                  "Condition": {
                      "ForAllValues:StringEquals": {
                          "dynamodb:Attributes": [
                              [Lists of attributes]
                          ]
                      }
                  }
              }
          ]
      }
  </code></pre>