Skip to content

Makes optional shared paths and basedir shared files creation#208

Merged
ricardclau merged 3 commits intoansistrano:masterfrom
skuark:master
Feb 22, 2017
Merged

Makes optional shared paths and basedir shared files creation#208
ricardclau merged 3 commits intoansistrano:masterfrom
skuark:master

Conversation

@skuark
Copy link

@skuark skuark commented Feb 21, 2017

Hi! I've updated ansistrano from an old version, and the project deployment has failed.

After investigating the problem, I've found a couple of tasks that were added in #142 to prepare shared folders before symlinking. It also makes sense for most of our projects and environments, but in a node from a particular client, the state: directory causes the task fails because the path exists as a symlink to another directory in the filesystem.

I think it could be good to make these tasks optional, enabled via ansible defaults, but overridable by the user. For now that approach is working for us.

@ricardclau
Copy link
Member

You are right, it is perhaps a bit of an edge case but it can be useful for cases like this one you are describing

Too bad it is all or nothing if you have 2 or 3 shared paths but in that case you could add the remaining ones in a hook

And no BC breaks which is great!

Copy link
Member

@ricardclau ricardclau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you please add these new variables to the README as well?

@skuark
Copy link
Author

skuark commented Feb 21, 2017

Of course, here it is. Thanks Ricard!

@ricardclau
Copy link
Member

Sorry to be picky with naming, I was checking this from my phone and did not check in depth.

I think the variables should be different in terms of pluralisation

ansistrano_ensure_shared_paths_exist instead of ansistrano_ensure_shared_paths_exists
ansistrano_ensure_basedirs_shared_files_exist instead of ansistrano_ensure_basedir_shared_files_exists

@skuark
Copy link
Author

skuark commented Feb 22, 2017

Don't worry, you are right. Fixed.

@ricardclau ricardclau merged commit ff3d20e into ansistrano:master Feb 22, 2017
@ricardclau
Copy link
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants