Skip to content
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

Restructure Release Drafter Flow #9345

Merged
merged 3 commits into from
Jan 19, 2024
Merged

Restructure Release Drafter Flow #9345

merged 3 commits into from
Jan 19, 2024

Conversation

Maffooch
Copy link
Contributor

This PR updates the structure and flow of the release drafter process. Now that OAS schemas are appended to each release object, it might be a better approach to make the release drafting process less event driven. Here is what the PR proposes:

  • Remove the trigger to run the release drafter on pushes to master
    • This is necessary as the docker images to generate the OAS schemas for a given release X are not public yet
    • One approach is to build the docker images before generating the release, but this slows down the release process overall
  • Explicitly run the release drafter workflow as step 2 of the release (this creates the the release, builds/uploads the helm chart, and pushes the newest images to dockerhub) only after the docker images have been pushed
    • The OAS schema generator will pull down the specified version of the. docker images, start them, generate the schemas, and then upload them to a cache where the release drafter will upload them to the correct release object along with the notes
  • The release object itself is manually published after verifying the contents have been generated/uploaded correctly, so if there are any failures here, we are able to debug what the issue is without losing too much of the process

@kiblik I encountered a few errors during the release this morning, and had a few thoughts to improve this process as I was going though it. I have not tested this PR in any capacity (it is a bit difficult to do that outside of releases) but please looks it over and let me know your thoughts. Here is the failed run from today

Copy link

dryrunsecurity bot commented Jan 16, 2024

Contextual Security Analysis

As DryRun Security performs checks, we’ll summarize them here. You can always dive into the detailed results in the section below for checks.

Status DryRun Security Check
AI-powered Sensitive Function Check
Configured Sensitive Files Check
AI-powered Sensitive Files Check

Chat with your AI-powered Security Buddy by typing @dryrunsecurity followed by your question into a comment.
Example: @dryrunsecurity What are common security issues with web application cookies?

Install and configure more repositories at DryRun Security

Copy link
Contributor

@kiblik kiblik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One small note but I agree in general

.github/workflows/fetch-oas.yml Outdated Show resolved Hide resolved
@Maffooch Maffooch marked this pull request as ready for review January 16, 2024 18:14
Copy link
Contributor

@mtesauro mtesauro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved

@mtesauro mtesauro merged commit d9f1a62 into bugfix Jan 19, 2024
123 checks passed
@kiblik
Copy link
Contributor

kiblik commented Jan 22, 2024

It failed again :( https://github.com/DefectDojo/django-DefectDojo/actions/runs/7614278448/job/20736452711
For some reason github.event.inputs.version has not been propagated.

@Maffooch
Copy link
Contributor Author

Weird right? I am confused why the release-number propagates, but version does not even when explicitly set... Will play around with this as I wait for the tests to run on the PRs from master to bugfix/dev
image

@Maffooch
Copy link
Contributor Author

Got very lucky finding this SO post. Seems to be the problem
https://stackoverflow.com/questions/71458189/github-action-workflow-call-does-not-use-up-to-date-input-values

@Maffooch
Copy link
Contributor Author

Got it working :) I think next weeks release will go off without a hitch now

https://github.com/DefectDojo/django-DefectDojo/releases/tag/2.30.3

@kiblik
Copy link
Contributor

kiblik commented Jan 22, 2024

Nice. Thank you :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants