Skip to content

add github-environment input for deploy jobs #2597

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from

Conversation

oraNod
Copy link
Contributor

@oraNod oraNod commented May 6, 2025

This change adds a github-environment input so that scheduled jobs that deploy doc builds use an environment without approval protection while jobs triggered manually require approval.

Reason for this change: scheduled builds for devel and latest result in multiple deployment reviews. We should require approval for manually triggered builds only.

@samccann has suggested simply removing the approval as a deployment protection step from the existing environment.

Alternatively, this change lets us keep the approvals but results in another environment that contains the private part of the deploy key.

We could potentially create a custom deployment protection rule but that requires a GitHub App and is a bit more complex.

This change adds a github-environment input so that scheduled jobs
that deploy doc builds use an environment without approval protection
while jobs triggered manually require approval.
@oraNod oraNod added doc builds Relates to building the documentation no_backport This PR should not be backported. devel only. labels May 6, 2025
@samccann
Copy link
Contributor

samccann commented May 7, 2025

alas not qualified to review but can you explain the end result here? We will still need to approve all automated builds or just the build to latest?

@oraNod
Copy link
Contributor Author

oraNod commented May 8, 2025

alas not qualified to review but can you explain the end result here? We will still need to approve all automated builds or just the build to latest?

@samccann This allows scheduled builds to deploy without approval. When someone manually kicks off a build, approval is still needed to deploy to test or prod (RTD).

As you mentioned in DaWGs this week, we can just remove the protection rule that requires approval for deployment. That seems like a good alternative to me but I'd like to hear what other folks think.

@oraNod oraNod closed this May 14, 2025
@oraNod oraNod reopened this May 14, 2025
@oraNod
Copy link
Contributor Author

oraNod commented May 14, 2025

@samccann I think we should just close this and remove the deployment protection rule as we discussed. It's probably overkill to duplicate the environments.

You also need to be a maintainer to trigger the workflow so it's not like some arbitrary person is going to kick off a build. And it's all in source control anyway so if something goes wrong, we can revert changes or just do a new build.

@oraNod oraNod closed this May 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
doc builds Relates to building the documentation no_backport This PR should not be backported. devel only.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants