{"action":"created","issue":{"url":"https://api.github.com/repos/cloudfoundry-community/bosh-init-bosh/issues/3","labels_url":"https://api.github.com/repos/cloudfoundry-community/bosh-init-bosh/issues/3/labels{/name}","comments_url":"https://api.github.com/repos/cloudfoundry-community/bosh-init-bosh/issues/3/comments","events_url":"https://api.github.com/repos/cloudfoundry-community/bosh-init-bosh/issues/3/events","html_url":"https://github.com/cloudfoundry-community/bosh-init-bosh/issues/3","id":71782527,"number":3,"title":"How to deploy to non-default VPC?","user":{"login":"robdimsdale","id":7230694,"avatar_url":"https://avatars.githubusercontent.com/u/7230694?v=3","gravatar_id":"","url":"https://api.github.com/users/robdimsdale","html_url":"https://github.com/robdimsdale","followers_url":"https://api.github.com/users/robdimsdale/followers","following_url":"https://api.github.com/users/robdimsdale/following{/other_user}","gists_url":"https://api.github.com/users/robdimsdale/gists{/gist_id}","starred_url":"https://api.github.com/users/robdimsdale/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/robdimsdale/subscriptions","organizations_url":"https://api.github.com/users/robdimsdale/orgs","repos_url":"https://api.github.com/users/robdimsdale/repos","events_url":"https://api.github.com/users/robdimsdale/events{/privacy}","received_events_url":"https://api.github.com/users/robdimsdale/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-04-29T05:25:38Z","updated_at":"2015-04-29T09:19:04Z","closed_at":"2015-04-29T05:38:39Z","body":"I'm trying to deploy to a non-default VPC and I get the following error:\r\n\r\n```\r\nCommand 'deploy' failed:\r\n  Deploying:\r\n    Creating instance 'bosh/0':\r\n      Creating VM:\r\n        Creating vm with stemcell cid 'ami-94c187fc light':\r\n          External CPI command for method 'create_vm' returned an error: CmdError{\"type\":\"Unknown\",\"message\":\"The security group 'sg-1781d773' does not exist in default VPC 'vpc-00e19e65'\",\"ok_to_retry\":false}\r\n```\r\n\r\nI then tried adding the subnet as per the [bosh docs](https://bosh.io/docs/aws-cpi.html):\r\n\r\n```\r\nnetworks:\r\n- name: default\r\n  type: dynamic\r\n  cloud_properties:\r\n    subnet: subnet-1781d773\r\n```\r\n\r\nand got a different error:\r\n\r\n```\r\nCommand 'deploy' failed:\r\n  Deploying:\r\n    Creating instance 'bosh/0':\r\n      Creating VM:\r\n        Creating vm with stemcell cid 'ami-94c187fc light':\r\n          External CPI command for method 'create_vm' returned an error: CmdError{\"type\":\"Unknown\",\"message\":\"When specifying a security group you must specify a group id for each item\",\"ok_to_retry\":false}\r\n```\r\n\r\nI appreciate this is probably a question for the bosh-aws-cpi rather than anything specific with this repo. But it might be something to add to the documentation for the various tutorials?"},"comment":{"url":"https://api.github.com/repos/cloudfoundry-community/bosh-init-bosh/issues/comments/97366862","html_url":"https://github.com/cloudfoundry-community/bosh-init-bosh/issues/3#issuecomment-97366862","issue_url":"https://api.github.com/repos/cloudfoundry-community/bosh-init-bosh/issues/3","id":97366862,"user":{"login":"robdimsdale","id":7230694,"avatar_url":"https://avatars.githubusercontent.com/u/7230694?v=3","gravatar_id":"","url":"https://api.github.com/users/robdimsdale","html_url":"https://github.com/robdimsdale","followers_url":"https://api.github.com/users/robdimsdale/followers","following_url":"https://api.github.com/users/robdimsdale/following{/other_user}","gists_url":"https://api.github.com/users/robdimsdale/gists{/gist_id}","starred_url":"https://api.github.com/users/robdimsdale/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/robdimsdale/subscriptions","organizations_url":"https://api.github.com/users/robdimsdale/orgs","repos_url":"https://api.github.com/users/robdimsdale/repos","events_url":"https://api.github.com/users/robdimsdale/events{/privacy}","received_events_url":"https://api.github.com/users/robdimsdale/received_events","type":"User","site_admin":false},"created_at":"2015-04-29T09:19:04Z","updated_at":"2015-04-29T09:19:04Z","body":"You mean EC2 vs VPC? My accounts are VPC-only.\r\n\r\nIt might be related, but I had to make some changes to the bosh micro yaml in order for it to deploy successfully:\r\n\r\n- manually configure networking:\r\n\r\n```\r\n- name: default\r\n  type: manual\r\n  ip: 10.0.0.6\r\n  netmask: 255.255.255.0\r\n  gateway: 10.0.0.1\r\n  dns: [10.0.0.6]\r\n  cloud_properties:\r\n    subnet: subnet-7e5b8155\r\n```\r\n\r\n- replace all instances of `127.0.0.1` with `10.0.0.6`\r\n\r\nafter doing that, bosh micro deploys fine with `./bin/deploy`"}}