Anyone here know about the aws cookbook? I’ve set it up just as described
here: https://github.com/opscode/cookbooks/tree/master/aws I’m using a new
recipe in my app’s own cookbook to set up an elastic ip, like so:
aws_elastic_ip “project_load_balancer_production” do
aws_access_key aws[‘aws_access_key_id’]
aws_secret_access_key aws[‘aws_secret_access_key’]
ip ip_info[‘public_ip’]
action :associate
end
FATAL: RightAws::AwsError: aws_elastic_ip[umbuc_load_balancer_production]
(caramel::elastic_ip line 15) had an error: MissingParameter: Either public
IP or allocation id must be specified
I get the same error if I enter all the data manually.
Anyone here know about the aws cookbook? I've set it up just as described
here: https://github.com/opscode/cookbooks/tree/master/aws I'm using a
new recipe in my app's own cookbook to set up an elastic ip, like so:
aws_elastic_ip "project_load_balancer_production" do
aws_access_key aws['aws_access_key_id']
aws_secret_access_key aws['aws_secret_access_key']
ip ip_info['public_ip']
action :associate
end
FATAL: RightAws::AwsError: aws_elastic_ip[umbuc_load_balancer_production]
(caramel::elastic_ip line 15) had an error: MissingParameter: Either public
IP or allocation id must be specified
I get the same error if I enter all the data manually.
Anyone here know about the aws cookbook? I've set it up just as described
here: https://github.com/opscode/cookbooks/tree/master/aws I'm using a
new recipe in my app's own cookbook to set up an elastic ip, like so:
aws_elastic_ip "project_load_balancer_production" do
aws_access_key aws['aws_access_key_id']
aws_secret_access_key aws['aws_secret_access_key']
ip ip_info['public_ip']
action :associate
end
FATAL: RightAws::AwsError: aws_elastic_ip[umbuc_load_balancer_production]
(caramel::elastic_ip line 15) had an error: MissingParameter: Either public
IP or allocation id must be specified
I get the same error if I enter all the data manually.
aws_elastic_ip "project_load_balancer_production" do
aws_access_key aws['aws_access_key_id']
aws_secret_access_key aws['aws_secret_access_key']
ip ip_info['public_ip']
action :associate
end
FATAL: RightAws::AwsError:
aws_elastic_ip[umbuc_load_balancer_production] (caramel::elastic_ip line
15) had an error: MissingParameter: Either public IP or allocation id must
be specified
I get the same error if I enter all the data manually.
That did it! However now I can't run the knife ssh command. I assume that's
because the node at OpsCode has a different public IP than the actual
instance does? The command I'm trying to run is:
aws_elastic_ip "project_load_balancer_production" do
aws_access_key aws['aws_access_key_id']
aws_secret_access_key aws['aws_secret_access_key']
ip ip_info['public_ip']
action :associate
end
FATAL: RightAws::AwsError:
aws_elastic_ip[umbuc_load_balancer_production] (caramel::elastic_ip line
15) had an error: MissingParameter: Either public IP or allocation id must
be specified
I get the same error if I enter all the data manually.
I just manually ssh'd in to the server (ssh ubunut@xxx.xxx.xxx.xxx) and ran
chef-client. It appears that resync'd the instance at OpsCode. I'm now able
to run the knife ssh command. Does that sound right?
That did it! However now I can't run the knife ssh command. I assume
that's because the node at OpsCode has a different public IP than the
actual instance does? The command I'm trying to run is:
aws_elastic_ip "project_load_balancer_production" do
aws_access_key aws['aws_access_key_id']
aws_secret_access_key aws['aws_secret_access_key']
ip ip_info['public_ip']
action :associate
end
FATAL: RightAws::AwsError:
aws_elastic_ip[umbuc_load_balancer_production] (caramel::elastic_ip line
15) had an error: MissingParameter: Either public IP or allocation id must
be specified
I get the same error if I enter all the data manually.
I just manually ssh'd in to the server (ssh ubunut@xxx.xxx.xxx.xxx) and ran
chef-client. It appears that resync'd the instance at OpsCode. I'm now able
It is possible that the instance hadn't populated that information
correctly with the server. It is hard to tell now that you fixed it,
so just glad it is working for you now.
Just want to note that there's now an ohai resource (added in 0.10 I
think?) that will do the reload as well that looks a little cleaner
(to my eyes at least), though does exactly the same thing: http://wiki.opscode.com/display/chef/Resources#Resources-Ohai
ohai "reload" do
action :reload
end
On Tue, Dec 6, 2011 at 10:42 AM, Joshua Timberman joshua@opscode.com wrote:
What happened, and this is normal without modification via a recipe:
Instance is launched rand new with no chef, original public ip from ec2 is assigned.
Chef gets installed and runs Ohai, which detects the ec2 assigned IP.
elastic ip is assigned by the recipe.
(at this point you may lose connectivity if you were on the ec2 assign ip)
chef run completes and the node is saved.
At no point does chef rerun Ohai to detect the ip. It is correct after chef runs again because the elastic ip is now the default.
You can initialize rerunning Ohai in a chef run like this:
o = Ohai::System.new
o.all_plugins
node.automatic_attrs.merge! o.data
Put that in a ruby_block so it happens during the execute phase of convergence. You can also call node.save explicitly in the ruby_block.
I just manually ssh'd in to the server (ssh ubunut@xxx.xxx.xxx.xxx) and ran
chef-client. It appears that resync'd the instance at OpsCode. I'm now able
It is possible that the instance hadn't populated that information
correctly with the server. It is hard to tell now that you fixed it,
so just glad it is working for you now.
I just manually ssh'd in to the server (ssh ubunut@xxx.xxx.xxx.xxx) and ran
chef-client. It appears that resync'd the instance at OpsCode. I'm now able
It is possible that the instance hadn't populated that information
correctly with the server. It is hard to tell now that you fixed it,
so just glad it is working for you now.