issues
search
Shopify
/
shipit-engine
Deployment coordination
https://shopify.engineering/introducing-shipit
MIT License
1.42k
stars
144
forks
source link
Rollback after abort when force param is used via api
#1244
Closed
stephsachrajda
closed
2 years ago
stephsachrajda
commented
2 years ago
What
So I believe this has actually been broken since it was added in
https://github.com/Shopify/shipit-engine/pull/1087
The issue is that while it correctly sets what to rollback to, without setting
rollback_once_aborted
the rollback will not trigger because that flag is checked before rolling back
https://github.com/Shopify/shipit-engine/blob/fcd420c2554e2b741d6595f365abbc2c0230bf06/app/models/shipit/deploy.rb#L288-L292
Even in the initial PR in test, both params are set
https://github.com/Shopify/shipit-engine/commit/d463adb758c29f38b9753a454a682c745f1a3f1e#diff-3130766d64891bca0b504fe915c08e798e04e2c9930cfeb64adc22ba60a7d8d0R312
I believe the need for two flags is that when empty we rollback to the last commit, though it may make sense to bypass this flag if the rollback_to is set 🤷♂️
What
rollback_once_aborted
the rollback will not trigger because that flag is checked before rolling back https://github.com/Shopify/shipit-engine/blob/fcd420c2554e2b741d6595f365abbc2c0230bf06/app/models/shipit/deploy.rb#L288-L292