0.10.RC Windows:site-cookbooks doesn't work

Hi,
Very excited about a version of knife and chef that runs from Windows as
that is what my dev environment is.

The site-cookbooks feature doesn’t work for me in Windows. It may be my
configuration though:
I have my chef-repo in an Eclipse workspace so it is not at ~/chef-repo.

In knife.rb
cookbook_path ["#{current_dir}/…/cookbooks",
"/c/Users/Edward/workspaces/TrailHunger-e3.4-3/chef-repo/site-cookbooks"]

knife cookbook upload does work but the files in site-cookbooks do
not override.

Is there something I’ve missed? The equivalent configuration worked in
Ubuntu 9 with Chef 0.9.

Cheers,
Edward

Potentially related to this?
http://tickets.opscode.com/browse/CHEF-2250

Thanks,
Matt Ray
Technical Evangelist | Opscode, Inc
E: matt@opscode.com T: (512) 731-2218
Twitter, Github: mattray

On Wed, Apr 20, 2011 at 9:21 PM, Edward Sargisson esarge@pobox.com wrote:

Hi,
Very excited about a version of knife and chef that runs from Windows as
that is what my dev environment is.

The site-cookbooks feature doesn't work for me in Windows. It may be my
configuration though:
I have my chef-repo in an Eclipse workspace so it is not at ~/chef-repo.

In knife.rb
cookbook_path ["#{current_dir}/../cookbooks",
"/c/Users/Edward/workspaces/TrailHunger-e3.4-3/chef-repo/site-cookbooks"]

knife cookbook upload does work but the files in site-cookbooks do
not override.

Is there something I've missed? The equivalent configuration worked in
Ubuntu 9 with Chef 0.9.

Cheers,
Edward

yeah I just raised that. I have no idea what's in the chef code but
it doesn't feel like it's related. Feels like the path lookup is doing
something strange in Windows. I think I'll raise a Jira for this one as
well.

Unfortunately, I'll have to roll back out of 0.10 but will happily test
anything for you.

Cheers,
Edward

On Thu, Apr 21, 2011 at 7:01 AM, Matt Ray matt@opscode.com wrote:

Potentially related to this?
http://tickets.opscode.com/browse/CHEF-2250

Thanks,
Matt Ray
Technical Evangelist | Opscode, Inc
E: matt@opscode.com T: (512) 731-2218
Twitter, Github: mattray

On Wed, Apr 20, 2011 at 9:21 PM, Edward Sargisson esarge@pobox.com
wrote:

Hi,
Very excited about a version of knife and chef that runs from Windows as
that is what my dev environment is.

The site-cookbooks feature doesn't work for me in Windows. It may be my
configuration though:
I have my chef-repo in an Eclipse workspace so it is not at ~/chef-repo.

In knife.rb
cookbook_path ["#{current_dir}/../cookbooks",
"/c/Users/Edward/workspaces/TrailHunger-e3.4-3/chef-repo/site-cookbooks"]

knife cookbook upload does work but the files in site-cookbooks do
not override.

Is there something I've missed? The equivalent configuration worked in
Ubuntu 9 with Chef 0.9.

Cheers,
Edward

I don't necessarily expect this to be the deal, however a related issue
arose with a Windows 0.10 beta tester, and part of the fix was upgrading
Ohai to the newest version. (
Ohai 0.6.2 Bugfix Release - Chef Blog | Chef)

Thanks,

Tom Thomas | Opscode, Inc.
tom@opscode.com | (c) 206.234.1193 | www.opscode.com

On Thu, Apr 21, 2011 at 7:40 AM, Edward Sargisson esarge@pobox.com wrote:

yeah I just raised that. I have no idea what's in the chef code but
it doesn't feel like it's related. Feels like the path lookup is doing
something strange in Windows. I think I'll raise a Jira for this one as
well.

Unfortunately, I'll have to roll back out of 0.10 but will happily test
anything for you.

Cheers,
Edward

On Thu, Apr 21, 2011 at 7:01 AM, Matt Ray matt@opscode.com wrote:

Potentially related to this?
http://tickets.opscode.com/browse/CHEF-2250

Thanks,
Matt Ray
Technical Evangelist | Opscode, Inc
E: matt@opscode.com T: (512) 731-2218
Twitter, Github: mattray

On Wed, Apr 20, 2011 at 9:21 PM, Edward Sargisson esarge@pobox.com
wrote:

Hi,
Very excited about a version of knife and chef that runs from Windows as
that is what my dev environment is.

The site-cookbooks feature doesn't work for me in Windows. It may be my
configuration though:
I have my chef-repo in an Eclipse workspace so it is not at ~/chef-repo.

In knife.rb
cookbook_path ["#{current_dir}/../cookbooks",

"/c/Users/Edward/workspaces/TrailHunger-e3.4-3/chef-repo/site-cookbooks"]

knife cookbook upload does work but the files in site-cookbooks
do
not override.

Is there something I've missed? The equivalent configuration worked in
Ubuntu 9 with Chef 0.9.

Cheers,
Edward

Hi,
I install ohai 0.6.2 and the cookbook site vendor and ec2 server create
problems persisted.

Cheers,
Edward

On Thu, Apr 21, 2011 at 7:54 AM, Tom Thomas tom@opscode.com wrote:

I don't necessarily expect this to be the deal, however a related issue
arose with a Windows 0.10 beta tester, and part of the fix was upgrading
Ohai to the newest version. (
Ohai 0.6.2 Bugfix Release - Chef Blog | Chef)

Thanks,

Tom Thomas | Opscode, Inc.
tom@opscode.com | (c) 206.234.1193 | www.opscode.com

On Thu, Apr 21, 2011 at 7:40 AM, Edward Sargisson esarge@pobox.comwrote:

yeah I just raised that. I have no idea what's in the chef code
but it doesn't feel like it's related. Feels like the path lookup is doing
something strange in Windows. I think I'll raise a Jira for this one as
well.

Unfortunately, I'll have to roll back out of 0.10 but will happily test
anything for you.

Cheers,
Edward

On Thu, Apr 21, 2011 at 7:01 AM, Matt Ray matt@opscode.com wrote:

Potentially related to this?
http://tickets.opscode.com/browse/CHEF-2250

Thanks,
Matt Ray
Technical Evangelist | Opscode, Inc
E: matt@opscode.com T: (512) 731-2218
Twitter, Github: mattray

On Wed, Apr 20, 2011 at 9:21 PM, Edward Sargisson esarge@pobox.com
wrote:

Hi,
Very excited about a version of knife and chef that runs from Windows
as
that is what my dev environment is.

The site-cookbooks feature doesn't work for me in Windows. It may be my
configuration though:
I have my chef-repo in an Eclipse workspace so it is not at
~/chef-repo.

In knife.rb
cookbook_path ["#{current_dir}/../cookbooks",

"/c/Users/Edward/workspaces/TrailHunger-e3.4-3/chef-repo/site-cookbooks"]

knife cookbook upload does work but the files in site-cookbooks
do
not override.

Is there something I've missed? The equivalent configuration worked in
Ubuntu 9 with Chef 0.9.

Cheers,
Edward

I wonder if AWS issues might be part of the cause (
http://status.aws.amazon.com/)... are you targeting a specific Availability
Zone?

Aside from that, you've validated the WinRM installation configuration?
(see http://wiki.opscode.com/display/chef/Knife+Windows+Bootstrap)

Thanks,

Tom Thomas | Opscode, Inc.
tom@opscode.com | (c) 206.234.1193 | www.opscode.com

On Fri, Apr 22, 2011 at 5:09 AM, Edward Sargisson esarge@pobox.com wrote:

Hi,
I install ohai 0.6.2 and the cookbook site vendor and ec2 server create
problems persisted.

Cheers,
Edward

On Thu, Apr 21, 2011 at 7:54 AM, Tom Thomas tom@opscode.com wrote:

I don't necessarily expect this to be the deal, however a related issue
arose with a Windows 0.10 beta tester, and part of the fix was upgrading
Ohai to the newest version. (
Ohai 0.6.2 Bugfix Release - Chef Blog | Chef)

Thanks,

Tom Thomas | Opscode, Inc.
tom@opscode.com | (c) 206.234.1193 | www.opscode.com

On Thu, Apr 21, 2011 at 7:40 AM, Edward Sargisson esarge@pobox.comwrote:

yeah I just raised that. I have no idea what's in the chef code
but it doesn't feel like it's related. Feels like the path lookup is doing
something strange in Windows. I think I'll raise a Jira for this one as
well.

Unfortunately, I'll have to roll back out of 0.10 but will happily test
anything for you.

Cheers,
Edward

On Thu, Apr 21, 2011 at 7:01 AM, Matt Ray matt@opscode.com wrote:

Potentially related to this?
http://tickets.opscode.com/browse/CHEF-2250

Thanks,
Matt Ray
Technical Evangelist | Opscode, Inc
E: matt@opscode.com T: (512) 731-2218
Twitter, Github: mattray

On Wed, Apr 20, 2011 at 9:21 PM, Edward Sargisson esarge@pobox.com
wrote:

Hi,
Very excited about a version of knife and chef that runs from Windows
as
that is what my dev environment is.

The site-cookbooks feature doesn't work for me in Windows. It may be
my
configuration though:
I have my chef-repo in an Eclipse workspace so it is not at
~/chef-repo.

In knife.rb
cookbook_path ["#{current_dir}/../cookbooks",

"/c/Users/Edward/workspaces/TrailHunger-e3.4-3/chef-repo/site-cookbooks"]

knife cookbook upload does work but the files in site-cookbooks
do
not override.

Is there something I've missed? The equivalent configuration worked in
Ubuntu 9 with Chef 0.9.

Cheers,
Edward

Hi Tom,
Yes I was targetting a specific Availability Zone. In order to bring my
production site back up I had to use Chef 0.9 and specify a region to bring
it up.

I've just tried the same command with 0.10.0.RC.0 and it still fails in
exactly the same way.

For clarity, I'm running Knife on a Windows client to startup an Ubuntu
instance in the cloud. The link below indicates that WinRM is required on
the Windows servers - not the client.
So, would you still like me to try it?

Cheers,
Edward

On Fri, Apr 22, 2011 at 10:20 AM, Tom Thomas tom@opscode.com wrote:

I wonder if AWS issues might be part of the cause (
http://status.aws.amazon.com/)... are you targeting a specific
Availability Zone?

Aside from that, you've validated the WinRM installation configuration?
(see http://wiki.opscode.com/display/chef/Knife+Windows+Bootstrap)

Thanks,

Tom Thomas | Opscode, Inc.
tom@opscode.com | (c) 206.234.1193 | www.opscode.com

On Fri, Apr 22, 2011 at 5:09 AM, Edward Sargisson esarge@pobox.comwrote:

Hi,
I install ohai 0.6.2 and the cookbook site vendor and ec2 server create
problems persisted.

Cheers,
Edward

On Thu, Apr 21, 2011 at 7:54 AM, Tom Thomas tom@opscode.com wrote:

I don't necessarily expect this to be the deal, however a related issue
arose with a Windows 0.10 beta tester, and part of the fix was upgrading
Ohai to the newest version. (
Ohai 0.6.2 Bugfix Release - Chef Blog | Chef)

Thanks,

Tom Thomas | Opscode, Inc.
tom@opscode.com | (c) 206.234.1193 | www.opscode.com

On Thu, Apr 21, 2011 at 7:40 AM, Edward Sargisson esarge@pobox.comwrote:

yeah I just raised that. I have no idea what's in the chef code
but it doesn't feel like it's related. Feels like the path lookup is doing
something strange in Windows. I think I'll raise a Jira for this one as
well.

Unfortunately, I'll have to roll back out of 0.10 but will happily test
anything for you.

Cheers,
Edward

On Thu, Apr 21, 2011 at 7:01 AM, Matt Ray matt@opscode.com wrote:

Potentially related to this?
http://tickets.opscode.com/browse/CHEF-2250

Thanks,
Matt Ray
Technical Evangelist | Opscode, Inc
E: matt@opscode.com T: (512) 731-2218
Twitter, Github: mattray

On Wed, Apr 20, 2011 at 9:21 PM, Edward Sargisson esarge@pobox.com
wrote:

Hi,
Very excited about a version of knife and chef that runs from Windows
as
that is what my dev environment is.

The site-cookbooks feature doesn't work for me in Windows. It may be
my
configuration though:
I have my chef-repo in an Eclipse workspace so it is not at
~/chef-repo.

In knife.rb
cookbook_path ["#{current_dir}/../cookbooks",

"/c/Users/Edward/workspaces/TrailHunger-e3.4-3/chef-repo/site-cookbooks"]

knife cookbook upload does work but the files in
site-cookbooks do
not override.

Is there something I've missed? The equivalent configuration worked
in
Ubuntu 9 with Chef 0.9.

Cheers,
Edward

On Fri, Apr 22, 2011 at 3:30 PM, Edward Sargisson esarge@pobox.com wrote:

Hi Tom,
Yes I was targetting a specific Availability Zone. In order to bring my
production site back up I had to use Chef 0.9 and specify a region to bring
it up.

I've just tried the same command with 0.10.0.RC.0 and it still fails in
exactly the same way.

if the chef version change had an impact, then it wasn't due to AWS issues.
I'll leave analysis on why Chef 0.9 v. 0.10.0.RC had an impact on the
issues' occurrence to someone more qualified than me.

For clarity, I'm running Knife on a Windows client to startup an Ubuntu
instance in the cloud. The link below indicates that WinRM is required on
the Windows servers - not the client.
So, would you still like me to try it?

ah, well then, probably not worth trying based in that :slight_smile: sorry I wasn't of
any help.

Cheers,
Edward

On Friday, April 22, 2011 at 7:01 PM, Tom Thomas wrote:

On Fri, Apr 22, 2011 at 3:30 PM, Edward Sargisson esarge@pobox.com wrote:

Hi Tom,
Yes I was targetting a specific Availability Zone. In order to bring my production site back up I had to use Chef 0.9 and specify a region to bring it up.

I've just tried the same command with 0.10.0.RC.0 and it still fails in exactly the same way.

if the chef version change had an impact, then it wasn't due to AWS issues. I'll leave analysis on why Chef 0.9 v. 0.10.0.RC had an impact on the issues' occurrence to someone more qualified than me.

For clarity, I'm running Knife on a Windows client to startup an Ubuntu instance in the cloud. The link below indicates that WinRM is required on the Windows servers - not the client.
So, would you still like me to try it?

ah, well then, probably not worth trying based in that :slight_smile: sorry I wasn't of any help.

Cheers,
Edward

In general, I'd recommend you migrate away from using site-cookbooks to stitch together modified cookbooks.

That said, to debug this issue, it'd help if you can add pp @cookbook_settings between line 67 and 68 of chef/cookbook/cookbook_version_loader.rb and look for anything that stands out (you can find the file with gem which chef/cookbook/cookbook_version_loader

--
Dan DeLeo

Hi,
I'll happily try those debug steps tonight. However, perhaps you could
explain somewhere (here or point me at an existing page) about how you
envision the use case being met in the future.
i.e. I want to take an existing cookbook, customise it a bit, but still be
able to pick up changes to the parent cookbook when they're made and I'm
happy with them.

Concrete example for discussion purposes: I recently took the wordpress
cookbook and had to modify it and the code around it in order to attach an
EBS volume for the database, include the FeedBurner plugin and my theme,
work with Apache and Tomcat so I can send tomcat traffic to tomcat and blog
traffic to Wordpress, etc.

Cheers,
Edward

On Wed, Apr 27, 2011 at 10:11 PM, Daniel DeLeo dan@kallistec.com wrote:

On Friday, April 22, 2011 at 7:01 PM, Tom Thomas wrote:

On Fri, Apr 22, 2011 at 3:30 PM, Edward Sargisson esarge@pobox.comwrote:

Hi Tom,
Yes I was targetting a specific Availability Zone. In order to bring my
production site back up I had to use Chef 0.9 and specify a region to bring
it up.

I've just tried the same command with 0.10.0.RC.0 and it still fails in
exactly the same way.

if the chef version change had an impact, then it wasn't due to AWS issues.
I'll leave analysis on why Chef 0.9 v. 0.10.0.RC had an impact on the
issues' occurrence to someone more qualified than me.

For clarity, I'm running Knife on a Windows client to startup an Ubuntu
instance in the cloud. The link below indicates that WinRM is required on
the Windows servers - not the client.
So, would you still like me to try it?

ah, well then, probably not worth trying based in that :slight_smile: sorry I wasn't
of any help.

Cheers,
Edward

In general, I'd recommend you migrate away from using site-cookbooks to
stitch together modified cookbooks.

That said, to debug this issue, it'd help if you can add pp @cookbook_settings between line 67 and 68 of
chef/cookbook/cookbook_version_loader.rb and look for anything that stands
out (you can find the file with gem which chef/cookbook/cookbook_version_loader

--
Dan DeLeo

On Fri, Apr 29, 2011 at 4:24 AM, Edward Sargisson esarge@pobox.com wrote:

Hi,
I'll happily try those debug steps tonight. However, perhaps you could
explain somewhere (here or point me at an existing page) about how you
envision the use case being met in the future.
i.e. I want to take an existing cookbook, customise it a bit, but still be
able to pick up changes to the parent cookbook when they're made and I'm
happy with them.

I think this is actually a very common need, and it is useful to see
if people can come up with innovate ways of addressing it or, at
least, maybe provide best practice recipes targeted at this sorts of
use cases.
Before you read the next sentence please resolve to read all that
follows. So I set up 0.

Now the caveats.

  • The Cookbooks account is still in the do-not-fork phase but will
    come out of that in the next week.
  • The master branch is used to track opscode/cookbooks and the 37s
    branch should, eventually, be updated with 37s changes (subject to
    demand, or more likely subject to pull requests)
  • The master branch is updated periodically but not yet on a
    schedule, that scheduled-time should be obvious to all, and easily
    converted to local time, so I'm thinking midnight GMT.
  • Github collaborators have not yet been solicited so, depending on
    their number, any pull requests might sit for a while, but that is
    fine - you have your fork in your site-cookbooks folder.
  • A best practice git-workflow has not been documented for people not
    familiar with git, for those who are: please ensure your pull request
    merges cleanly with the 'qa' branch, and document your reasons in the
    commit message. Remeber others are going to have to be convinced you
    change is a) good/best Chef practice (point to a url describing this
    is fine), b) good/best practice for the app being configured, likewise
    pointing to some blog/doc URL should suffice, after all it is the
    internet age, and you are that generation :wink:
  • The cuken project will make using these repos both documentable
    (see [1]), executable and painless (or less-painful), but that project
    too is in raw-meat/alpha stage....
  • The cuken project should be usable when I have chef-server 0.10.x
    bootstrap-able from a Vagrantfile, and there have been several chef
    issues blocking that (see my earlier mail thread), currently there is
    one issue blocking this, but who knows what lies beyond that.
  • The Bundler experiment failed, and should be considered dead or, at
    best, in a cryogenic tank. Not because the idea of resolving
    dependencies via Bundler, or some other library, is bad, but because
    Bundler's code base was so horrific to work with and bundler core
    (indirect) have also explicitly indicated Bundler's many git repo
    gem-source 'issues', are not pain points for them right now.

While this is still a wip I HTH?

[1]: http://relishapp.com among others

Concrete example for discussion purposes: I recently took the wordpress
cookbook and had to modify it and the code around it in order to attach an
EBS volume for the database, include the FeedBurner plugin and my theme,
work with Apache and Tomcat so I can send tomcat traffic to tomcat and blog
traffic to Wordpress, etc.

Cheers,
Edward

On Wed, Apr 27, 2011 at 10:11 PM, Daniel DeLeo dan@kallistec.com wrote:

On Friday, April 22, 2011 at 7:01 PM, Tom Thomas wrote:

On Fri, Apr 22, 2011 at 3:30 PM, Edward Sargisson esarge@pobox.com
wrote:

Hi Tom,
Yes I was targetting a specific Availability Zone. In order to bring my
production site back up I had to use Chef 0.9 and specify a region to bring
it up.

I've just tried the same command with 0.10.0.RC.0 and it still fails in
exactly the same way.

if the chef version change had an impact, then it wasn't due to AWS
issues. I'll leave analysis on why Chef 0.9 v. 0.10.0.RC had an impact on
the issues' occurrence to someone more qualified than me.

For clarity, I'm running Knife on a Windows client to startup an Ubuntu
instance in the cloud. The link below indicates that WinRM is required on
the Windows servers - not the client.
So, would you still like me to try it?

ah, well then, probably not worth trying based in that :slight_smile: sorry I wasn't
of any help.

Cheers,
Edward

In general, I'd recommend you migrate away from using site-cookbooks to
stitch together modified cookbooks.
That said, to debug this issue, it'd help if you can add pp @cookbook_settings between line 67 and 68 of
chef/cookbook/cookbook_version_loader.rb and look for anything that stands
out (you can find the file with gem which chef/cookbook/cookbook_version_loader

--
Dan DeLeo

--
πόλλ' οἶδ ἀλώπηξ, ἀλλ' ἐχῖνος ἓν μέγα
[The fox knows many things, but the hedgehog knows one big thing.]
Archilochus, Greek poet (c. 680 BC – c. 645 BC)
http://wiki.hedgehogshiatus.com

Okay... so if I understand the intent then, to take my concrete example:
Business need: The wordpress recipe doesn't quite work for me because it
publishes an apache wordpress.conf only for workpress and not to connect to
Tomcat as my site needs.

So I should fork the wordpress recipe, make a change so that the generation
of the wordpress.conf can be suppressed based on an attribute and put the
resulting change into the repository you created at 0 below so that it can
be picked up if considered useful.

Then my local recipe becomes:

  • set the attribute to suppress wordpress.conf
  • include_recipe wordpress
  • generate the site specific .conf

Am I understanding things?

Cheers,
Edward

On Thu, Apr 28, 2011 at 3:44 PM, Hedge Hog hedgehogshiatus@gmail.comwrote:

On Fri, Apr 29, 2011 at 4:24 AM, Edward Sargisson esarge@pobox.com
wrote:

Hi,
I'll happily try those debug steps tonight. However, perhaps you could
explain somewhere (here or point me at an existing page) about how you
envision the use case being met in the future.
i.e. I want to take an existing cookbook, customise it a bit, but still
be
able to pick up changes to the parent cookbook when they're made and I'm
happy with them.

I think this is actually a very common need, and it is useful to see
if people can come up with innovate ways of addressing it or, at
least, maybe provide best practice recipes targeted at this sorts of
use cases.
Before you read the next sentence please resolve to read all that
follows. So I set up 0.

Now the caveats.

  • The Cookbooks account is still in the do-not-fork phase but will
    come out of that in the next week.
  • The master branch is used to track opscode/cookbooks and the 37s
    branch should, eventually, be updated with 37s changes (subject to
    demand, or more likely subject to pull requests)
  • The master branch is updated periodically but not yet on a
    schedule, that scheduled-time should be obvious to all, and easily
    converted to local time, so I'm thinking midnight GMT.
  • Github collaborators have not yet been solicited so, depending on
    their number, any pull requests might sit for a while, but that is
    fine - you have your fork in your site-cookbooks folder.
  • A best practice git-workflow has not been documented for people not
    familiar with git, for those who are: please ensure your pull request
    merges cleanly with the 'qa' branch, and document your reasons in the
    commit message. Remeber others are going to have to be convinced you
    change is a) good/best Chef practice (point to a url describing this
    is fine), b) good/best practice for the app being configured, likewise
    pointing to some blog/doc URL should suffice, after all it is the
    internet age, and you are that generation :wink:
  • The cuken project will make using these repos both documentable
    (see [1]), executable and painless (or less-painful), but that project
    too is in raw-meat/alpha stage....
  • The cuken project should be usable when I have chef-server 0.10.x
    bootstrap-able from a Vagrantfile, and there have been several chef
    issues blocking that (see my earlier mail thread), currently there is
    one issue blocking this, but who knows what lies beyond that.
  • The Bundler experiment failed, and should be considered dead or, at
    best, in a cryogenic tank. Not because the idea of resolving
    dependencies via Bundler, or some other library, is bad, but because
    Bundler's code base was so horrific to work with and bundler core
    (indirect) have also explicitly indicated Bundler's many git repo
    gem-source 'issues', are not pain points for them right now.

While this is still a wip I HTH?

[1]: http://relishapp.com among others

Concrete example for discussion purposes: I recently took the wordpress
cookbook and had to modify it and the code around it in order to attach
an
EBS volume for the database, include the FeedBurner plugin and my theme,
work with Apache and Tomcat so I can send tomcat traffic to tomcat and
blog
traffic to Wordpress, etc.

Cheers,
Edward

On Wed, Apr 27, 2011 at 10:11 PM, Daniel DeLeo dan@kallistec.com
wrote:

On Friday, April 22, 2011 at 7:01 PM, Tom Thomas wrote:

On Fri, Apr 22, 2011 at 3:30 PM, Edward Sargisson esarge@pobox.com
wrote:

Hi Tom,
Yes I was targetting a specific Availability Zone. In order to bring my
production site back up I had to use Chef 0.9 and specify a region to
bring
it up.

I've just tried the same command with 0.10.0.RC.0 and it still fails in
exactly the same way.

if the chef version change had an impact, then it wasn't due to AWS
issues. I'll leave analysis on why Chef 0.9 v. 0.10.0.RC had an impact
on
the issues' occurrence to someone more qualified than me.

For clarity, I'm running Knife on a Windows client to startup an Ubuntu
instance in the cloud. The link below indicates that WinRM is required
on
the Windows servers - not the client.
So, would you still like me to try it?

ah, well then, probably not worth trying based in that :slight_smile: sorry I
wasn't
of any help.

Cheers,
Edward

In general, I'd recommend you migrate away from using site-cookbooks to
stitch together modified cookbooks.
That said, to debug this issue, it'd help if you can add pp @cookbook_settings between line 67 and 68 of
chef/cookbook/cookbook_version_loader.rb and look for anything that
stands
out (you can find the file with gem which chef/cookbook/cookbook_version_loader

--
Dan DeLeo

--
πόλλ' οἶδ ἀλώπηξ, ἀλλ' ἐχῖνος ἓν μέγα
[The fox knows many things, but the hedgehog knows one big thing.]
Archilochus, Greek poet (c. 680 BC – c. 645 BC)
http://wiki.hedgehogshiatus.com

On Thursday, April 28, 2011 at 4:05 PM, Edward Sargisson wrote:
Okay... so if I understand the intent then, to take my concrete example:

Business need: The wordpress recipe doesn't quite work for me because it publishes an apache wordpress.conf only for workpress and not to connect to Tomcat as my site needs.

So I should fork the wordpress recipe, make a change so that the generation of the wordpress.conf can be suppressed based on an attribute and put the resulting change into the repository you created at [0] below so that it can be picked up if considered useful.

Then my local recipe becomes:

  • set the attribute to suppress wordpress.conf
  • include_recipe wordpress
  • generate the site specific .conf

Am I understanding things?
What I recommend is to use knife cookbook site install. It's unfortunate that this is also broken for you on windows at the moment. Anyway, the "vendor branch" strategy reduces the amount of code you need to duplicate when modifying upstream cookbooks. With the file-shadowing approach, you might need to copy all of a 100 line file just to add a few lines. The file shadowing strategy is also more difficult to understand, since the entire cookbook is no longer in one place.

Despite the above, the shadowing approach is still supported, even if discouraged, so I'll be happy to check out your debugging output to see what's going on.

Cheers,
Edward

--
Dan DeLeo

On Fri, Apr 29, 2011 at 9:05 AM, Edward Sargisson esarge@pobox.com wrote:

Okay... so if I understand the intent then, to take my concrete example:
Business need: The wordpress recipe doesn't quite work for me because it
publishes an apache wordpress.conf only for workpress and not to connect to
Tomcat as my site needs.

So I should fork the wordpress recipe, make a change so that the generation
of the wordpress.conf can be suppressed based on an attribute and put the
resulting change into the repository you created at 0 below so that it can
be picked up if considered useful.

Pretty much, the devil-in-the-detail part is getting your merge
request in a state that makes it easy for a cookbook maintainer to
merge the whole set of changes or cherry pick only some coherent
parts.
If you are not very familiar with Git, e.g squash when rebasing, then
it may be easiest for you to do what Dan DeLeo suggests. The cuken
and cookbooks account are really bleeding edge suck-it-and-see
exercises right now.

Then my local recipe becomes:

  • set the attribute to suppress wordpress.conf
  • include_recipe wordpress
  • generate the site specific .conf

Am I understanding things?

Cheers,
Edward

On Thu, Apr 28, 2011 at 3:44 PM, Hedge Hog hedgehogshiatus@gmail.com
wrote:

On Fri, Apr 29, 2011 at 4:24 AM, Edward Sargisson esarge@pobox.com
wrote:

Hi,
I'll happily try those debug steps tonight. However, perhaps you could
explain somewhere (here or point me at an existing page) about how you
envision the use case being met in the future.
i.e. I want to take an existing cookbook, customise it a bit, but still
be
able to pick up changes to the parent cookbook when they're made and I'm
happy with them.

I think this is actually a very common need, and it is useful to see
if people can come up with innovate ways of addressing it or, at
least, maybe provide best practice recipes targeted at this sorts of
use cases.
Before you read the next sentence please resolve to read all that
follows. So I set up 0.

Now the caveats.

  • The Cookbooks account is still in the do-not-fork phase but will
    come out of that in the next week.
  • The master branch is used to track opscode/cookbooks and the 37s
    branch should, eventually, be updated with 37s changes (subject to
    demand, or more likely subject to pull requests)
  • The master branch is updated periodically but not yet on a
    schedule, that scheduled-time should be obvious to all, and easily
    converted to local time, so I'm thinking midnight GMT.
  • Github collaborators have not yet been solicited so, depending on
    their number, any pull requests might sit for a while, but that is
    fine - you have your fork in your site-cookbooks folder.
  • A best practice git-workflow has not been documented for people not
    familiar with git, for those who are: please ensure your pull request
    merges cleanly with the 'qa' branch, and document your reasons in the
    commit message. Remeber others are going to have to be convinced you
    change is a) good/best Chef practice (point to a url describing this
    is fine), b) good/best practice for the app being configured, likewise
    pointing to some blog/doc URL should suffice, after all it is the
    internet age, and you are that generation :wink:
  • The cuken project will make using these repos both documentable
    (see [1]), executable and painless (or less-painful), but that project
    too is in raw-meat/alpha stage....
  • The cuken project should be usable when I have chef-server 0.10.x
    bootstrap-able from a Vagrantfile, and there have been several chef
    issues blocking that (see my earlier mail thread), currently there is
    one issue blocking this, but who knows what lies beyond that.
  • The Bundler experiment failed, and should be considered dead or, at
    best, in a cryogenic tank. Not because the idea of resolving
    dependencies via Bundler, or some other library, is bad, but because
    Bundler's code base was so horrific to work with and bundler core
    (indirect) have also explicitly indicated Bundler's many git repo
    gem-source 'issues', are not pain points for them right now.

While this is still a wip I HTH?

[1]: http://relishapp.com among others

Concrete example for discussion purposes: I recently took the wordpress
cookbook and had to modify it and the code around it in order to attach
an
EBS volume for the database, include the FeedBurner plugin and my theme,
work with Apache and Tomcat so I can send tomcat traffic to tomcat and
blog
traffic to Wordpress, etc.

Cheers,
Edward

On Wed, Apr 27, 2011 at 10:11 PM, Daniel DeLeo dan@kallistec.com
wrote:

On Friday, April 22, 2011 at 7:01 PM, Tom Thomas wrote:

On Fri, Apr 22, 2011 at 3:30 PM, Edward Sargisson esarge@pobox.com
wrote:

Hi Tom,
Yes I was targetting a specific Availability Zone. In order to bring my
production site back up I had to use Chef 0.9 and specify a region to
bring
it up.

I've just tried the same command with 0.10.0.RC.0 and it still fails in
exactly the same way.

if the chef version change had an impact, then it wasn't due to AWS
issues. I'll leave analysis on why Chef 0.9 v. 0.10.0.RC had an impact
on
the issues' occurrence to someone more qualified than me.

For clarity, I'm running Knife on a Windows client to startup an Ubuntu
instance in the cloud. The link below indicates that WinRM is required
on
the Windows servers - not the client.
So, would you still like me to try it?

ah, well then, probably not worth trying based in that :slight_smile: sorry I
wasn't
of any help.

Cheers,
Edward

In general, I'd recommend you migrate away from using site-cookbooks to
stitch together modified cookbooks.
That said, to debug this issue, it'd help if you can add pp @cookbook_settings between line 67 and 68 of
chef/cookbook/cookbook_version_loader.rb and look for anything that
stands
out (you can find the file with gem which chef/cookbook/cookbook_version_loader

--
Dan DeLeo

--
πόλλ' οἶδ ἀλώπηξ, ἀλλ' ἐχῖνος ἓν μέγα
[The fox knows many things, but the hedgehog knows one big thing.]
Archilochus, Greek poet (c. 680 BC – c. 645 BC)
http://wiki.hedgehogshiatus.com

--
πόλλ' οἶδ ἀλώπηξ, ἀλλ' ἐχῖνος ἓν μέγα
[The fox knows many things, but the hedgehog knows one big thing.]
Archilochus, Greek poet (c. 680 BC – c. 645 BC)
http://wiki.hedgehogshiatus.com