Drupal 10, the latest version of the open-source digital experience platform with even more features, is here.I'm listing this as a feature request, but it could just as easily be considered a bug. If a site is on a platform on a remote server, a 'git pull' won't have any effect on the site being served, until it is verified, and thus sync'd out to the remote.
| Comment | File | Size | Author |
|---|---|---|---|
| #15 | trigger-verify-after-pull-checkout-2541758-14.patch | 3.31 KB | formatC'vt |











Comments
Comment #1
ergonlogicThis will probably equally apply when the platform is managed under git.
Comment #2
formatC'vt CreditAttribution: formatC'vt as a volunteer commentedi'm working on it
Comment #3
formatC'vt CreditAttribution: formatC'vt as a volunteer commentedAdded an option with trigger flag (checkbox) to git settings
Comment #4
helmo CreditAttribution: helmo as a volunteer and at Initfour websolutions commentedNot sure what is going wrong but we already have code for that ... http://cgit.drupalcode.org/hosting_git/tree/pull/hosting_git_pull.module...
Comment #5
formatC'vt CreditAttribution: formatC'vt as a volunteer commentedalso we have this http://cgit.drupalcode.org/hosting_git/tree/checkout/hosting_git_checkou...
but those hooks are not invoked.
"Verify" after "Git checkout" invoked here http://cgit.drupalcode.org/hosting_git/tree/hosting_git.drush.inc#n75
Comment #6
ergonlogicIt looks like these hooks are in the
.module, which'd explain why they aren't being invoked. I'm pretty sure they'd have to live in a.drush.incfor that.Comment #7
formatC'vt CreditAttribution: formatC'vt as a volunteer commentedI think you are right. But what is the best way to implement this issue
hook_post_hosting_TASK_TYPE_task()ordrush_hook_post_COMMAND()?Comment #8
ergonlogicdrush_hosting_git_pull_post_provision_git_pull(), as written, should work just fine, assuming it's moved to a file calledhosting_git_pull.drush.inc.In this case, the Drush hook is preferable, since the verify is an integral part of the git pull operation. That is, we want it to happen, even if there is no front-end triggering it. In the hosting post task hook, we'd have to queue up the verify task, which is a counter-pattern in general.
Comment #9
formatC'vt CreditAttribution: formatC'vt as a volunteer commentedok, i will try this way
Comment #10
ergonlogicSince we already have code intended to do this, the fact that it isn't working is clearly a bug.
Also, I don't really think we need a front-end flag for this. Without a verify, the updated code won't propagate. I don't see a use-case for not running the verify, especially since it will attempt to fix permissions, etc.
Comment #11
helmo CreditAttribution: helmo as a volunteer and at Initfour websolutions commentedI just tried this again in production and for me it "just works". The code was pulled on the master server and rsync'd to the slave server.
Comment #12
formatC'vt CreditAttribution: formatC'vt as a volunteer commentedrsync'd without verify task?
Comment #13
ergonlogicI'm not seeing the behaviour in #11. There's no verify/rsync happening in my tests.
Comment #14
formatC'vt CreditAttribution: formatC'vt as a volunteer commentedMaybe he uses checkout instead pull. Anyway i'm working on it, but just create files
'MODULE_NAME.drush.inc'and add hooksdrush_hosting_git_pull_post_provision_git_pull()anddrush_hosting_git_checkout_post_provision_git_checkout()not working. I will try find enough time on this week to find what is wrong and why these hooks not invoked.Comment #15
formatC'vt CreditAttribution: formatC'vt as a volunteer commenteddone
Comment #16
gboudrias CreditAttribution: gboudrias at Praxis Labs Coop commentedComment #17
cweagansI haven't tested this on a real Aegir install, but it looks good to me. It's just moving code around as far as I can tell. I won't RTBC, but if somebody else wants to test it and make sure it works as expected, feel free to consider the code reviewed :)
Comment #18
gboudrias CreditAttribution: gboudrias at Praxis Labs Coop commentedComment #19
helmo CreditAttribution: helmo as a volunteer and at Initfour websolutions commentedSorry but the patch from #15 is not good for me.
On a checkout task I without the patch I get a verify, with the patch applied no verify happens.
I think #3had a better hook for a verify after pull.
Comment #20
formatC'vt CreditAttribution: formatC'vt as a volunteer commentedWithout patch the verify is separate task in UI, with patch the verify is an integral part of the git checkout operation (not a separate task in UI). Check task log for
Calling hook drush_provision_git_post_provision_verifypleaseComment #22
helmo CreditAttribution: helmo as a volunteer and at Initfour websolutions commentedSeems to work now, committed. I also moved more code to the pull and checkout sub modules.
It might have been Drush not picking up the new command files until the hostmaster site was re-verified.