[chef] Re: application(_php) cookbook deletes subtree before symlinking


Chronological Thread 
  • From: Cassiano Leal < >
  • To:
  • Subject: [chef] Re: application(_php) cookbook deletes subtree before symlinking
  • Date: Thu, 4 Jul 2013 11:36:36 -0300

Ugh... Nevermind.

I had set

purge_before_symlink [
  “data/"
]

which was causing the deletion of the subtree. Changed it to

purge_before_symlink [
  “data"
]

and all is good now, apart from my feeling a bit stupid. :)

- cassiano

On Thursday, July 4, 2013 at 11:29, Cassiano Leal wrote:

Ohai!

I am trying to deploy an application using the application_php cookbook. Most of it works as expected, but there’s still one detail to set straight before calling it done.

The application logs stuff to data/log/application.log, relative to its root location. 

I want the logs to survive deploys, so the obvious thing to do is to have data/log inside the shared/ sirectory, and symlinking one to the other.

I’m doing this through the symlink_before_migrate attribute of the application resource, like such:

symlink_before_migrate(
  ‘data’ => ‘'
)

The weird thing is: it does the symlinking flawlessly, I have current/data linked to shared/data just fine, but everything inside it gets purged, meaning that my logs are gone after each deploy (and the whole data/* subtree for that matter).

I couldn’t find the symlinking code in the application and application_php cookbooks either.

Am I doing something wrong, have I hit a bug that should be ticketed, or something else?

Appreciate your pointers.

Cheers,
- cassiano





Archive powered by MHonArc 2.6.16.

§