scalr-integrations/kitchen-scalr

API v2 farm role changes seem to break creation

Opened this issue · 1 comments

It looks like the breaking API v2 changes detailed here: https://scalr-wiki.atlassian.net/wiki/spaces/docs/pages/88276995/Moving+AWS+VPC+settings+from+the+Farm+level+to+the+Farm+Role+level

breaks the farm role creation with the following error:
{"meta":{"requestId":"51e45c56-61dc-4781-84f4-10a37d371ff8","stringToSign":"POST\n2018-01-04T15:25:22Z+00:00\n\/api\/v1beta0\/user\/6\/farms\/4467\/farm-roles\/\n\n{\"alias\":\"KITCHEN-ROLE-33a87a14-3f5b-4b31-b2f0-ccfc3476f8e0\",\"cloudPlatform\":\"ec2\",\"cloudLocation\":\"\",\"instanceType\":{\"id\":\"t2.medium\"},\"role\":{\"id\":79122},\"scaling\":{\"enabled\":true},\"security\":{\"securityGroups\":[{\"id\":\"sg-524b882f\"},{\"id\":\"sg-3f2b1047\"},{\"id\":\"sg-xxxx\"},{\"id\":\"sg-xxxx\"},{\"id\":\"sg-xxxx\"},{\"id\":\"sg-xxxx\"}]}}"},"errors":[{"code":"InvalidStructure","message":"Property 'cloudLocation' is missing."}]}

I believe this is due to the cloudLocation/Placement field being moved into the farm role. We're using Scalr 7.7.8 and kitchen-scalr 0.2.5.

Let me know if you need any further info

Hi Brian,

I was unable to reproduce this error. Looking at the error message, it looks like kitchen-scalr is not picking up the cloudLocation for the farm role, is the scalr_location setting correctly set in the driver config in your .kitchen.yml?

If this does not resolve your issue, please also try to upgrade kitchen-scalr to 0.2.6.