habitat-sh / builder

Habitat Builder
Apache License 2.0
33 stars 35 forks source link

.bldr.toml should allow users to auto-promote to channels other than unstable #99

Closed elliott-davis closed 3 years ago

elliott-davis commented 6 years ago

@tashimi commented on Sat Dec 16 2017

This is expected/documented behavior but apparently doesn't exist in the code base.

Additional channel promotion

-You can specify a list of additional channels that packages should automatically publish to. By default, software is only published to the unstable channel.

-toml -# .bldr.toml -[hab-launcher] -channels = ["stable"] -


@tashimi commented on Sat Dec 16 2017

Aha! Link: https://chef.aha.io/features/APPDL-67

smartb-pair commented 6 years ago

@tashimi / @elliott-davis, as of today this has become production-critical for us (had a minor production outage because of the "Polka Problem" described here, which we think can be circumvented by auto-promoting our origin's packages to a staging channel or similar and then setting HAB_BLDR_CHANNEL to staging in our Builder secrets.

cc: @bixu

smartb-pair commented 6 years ago

(It seems at the moment that our only alternative is to stop using Builder entirely and retain only the artifact storage (Depot) functionality.)

raskchanky commented 6 years ago

I did some research yesterday into what it would take to enable this feature and it doesn't look that bad. It looks like it was at least partially implemented at some point in the past, because the .bldr.toml file has support in it for channels. @chefsalim mentioned that he removed parts of this feature at one point, but I'm not clear what the reasons were for that, or if there's something preventing us from putting it back together.

chefsalim commented 6 years ago

The feature was removed as it was broken and needed re-design - the promote then was happening in the job scheduler, which is not where we want actual job tasks to happen. Also the bldr.toml could override the sandboxing the way the original implementation worked, which is not what we want.

So from a requirements perspective, the decisions to be made are around:

rsertelon commented 6 years ago

My 2cts here:

raskchanky commented 6 years ago

My thoughts:

rsertelon commented 6 years ago

@raskchanky re stable being one of the channels. I think technically, it works if all jobs succeed indeed. I was thinking core-plans and I think there we should forbid that (at least for now?), but that could be done in a travis check maybe.

raskchanky commented 6 years ago

@rsertelon That's a fair point, and we might also be able to include that as a configuration option inside the .bldr.toml file. Something like promotion_to_stable_allowed = true, so it could be tweaked as needed.

stale[bot] commented 4 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. We value your input and contribution. Please leave a comment if this issue still affects you.

stale[bot] commented 3 years ago

This issue has been automatically closed after being stale for 400 days. We still value your input and contribution. Please re-open the issue if desired and leave a comment with details.