This now bundles a platform_git module that seems to have overlap with hosting_git.
Was the desire for OO code the reason for this?
This now bundles a platform_git module that seems to have overlap with hosting_git.
Was the desire for OO code the reason for this?
Comments
Comment #2
ergonlogicThe main goal was to have a minimalist, safe git-based platform deployment mechanism.
hosting_gitprovides various tasks such as 'pull' and 'checkout' that, while useful in a development scenario, are dangerous for a production multi-site deployment.OOP was another reason, though. It should also simplify #2871776: Support altering the 'git' command in support of #2868517: Support private git repos.
Comment #3
jon pughI strongly believe we should put support for git and composer directly in Aegir core. It's just as relevant as drush make based platforms at this point. Having written a ton of hosting_git, and a ton of devshop, I can tell you that treating git and composer would be MUCH easier and much less code if it were in core Aegir.
Comment #4
colanAs a way forward with this module and Aegir Distributions, does this make sense as a plan?
@Jon Pugh: Placing things in the Golden list (instead of Aegir core) keeps us in line with the microkernel philosophy. We would be able to swap out separate components and replace them on their own, without having to deal with a huge monolithic Aegir. This make upgrades like AegirNG much easier to divide and conquer.
@ergonlogic: Given your response above, can we assume that you no longer have faith in a solution that uses your patch at https://www.drupal.org/node/2736801#comment-12034550, given that it's for hosting_git? If this is in fact the case, we should state that in the issue over there.
Comment #5
ergonlogicOOP is certainly preferable. It makes for much cleaner code, and may allow some of it to more easily be ported to Drupal 8 down the road. But that's not the main reason for creating
platform_git.The main reasons are illustrated best by the inline documentation from
platform_git:... and
hosting_deploy:So,
hosting_gitandhosting_platform_gitreally satisfy different use-cases. In my opinion, trying to shoe-horn the two into a single implementation has been counter-productive.Additional functionality is also distinct from anything to do with git, as illustrated in the "distro" branch of the docs (which is awaiting a merge, btw):
Comment #6
ergonlogicI get where you're coming from, but when we make a sub-system pluggable, the trade-off is that there'll be more required boilerplate.
In retrospect, I think including Drush Make in platforms directly was a mistake, and part of the reason it can be hard to alter platform deployment behaviour. Had we, instead, recognized that platform deployment should itself be a pluggable sub-system, I think we could have provided a framework to minimize the boilerplate (and complexity) of adding new deployment mechanisms.
I've tried to begin addressing this with the
hosting_deploymodule (a sub-module ofhosting_composer) to clean up the front-end, at least. Future iterations (or versions) should go further and address the back-end too.Comment #7
ergonlogicAs a way forward with this module and Aegir Distributions, does this make sense as a plan?
Add any missing features from hosting_git.For hosting_git features that are "dangerous", let's add warnings to the UI.Remove hosting_git from the Golden list.As I stated earlier,
hosting_platform_gitis really meant to exist alongsidehosting_git, so (2) and (5) aren't needed. (3) should really be discussed in thehosting_gitissue queue, imo.So, that leaves stabilize this module and then add it to Golden Contrib, which I strongly support. I think the next step is to get some broader testing, so let's release a beta and follow-up in #2876247: [meta] 3.0 release of Aegir Composer.
Comment #8
ergonlogicOh, and in case it wasn't obvious, I think the approach in this module is preferable to the patch in #2736801: Support Composer for platform builds. I'll update that issue too.
Comment #9
helmo commentedOK, lets get this stable and ready for 3.13