Skip to content

Conversation

@carlosmt86
Copy link

@carlosmt86 carlosmt86 commented Oct 23, 2025

Fixes: #13391

⚠️ Pre-Approval check ⚠️

We don't want to waste your time, so if you're unsure whether your hypothetical enhancement meets the criteria for approval, please file an issue to get pre-approval before beginning work on a PR.
Learn more here: https://github.com/DefectDojo/django-DefectDojo/blob/master/readme-docs/CONTRIBUTING.md#submission-pre-approval

Description

Describe the feature / bug fix implemented by this PR.
If this is a new parser, the parser guide may be worth (re)reading.

Test results

Ideally you extend the test suite in tests/ and dojo/unittests to cover the changed in this PR.
Alternatively, describe what you have and haven't tested.

Documentation

Please update any documentation when needed in the documentation folder)

Checklist

This checklist is for your information.

  • Make sure to rebase your PR against the very latest dev.
  • Features/Changes should be submitted against the dev.
  • Bugfixes should be submitted against the bugfix branch.
  • Give a meaningful name to your PR, as it may end up being used in the release notes.
  • Your code is flake8 compliant.
  • Your code is python 3.12 compliant.
  • If this is a new feature and not a bug fix, you've included the proper documentation in the docs at https://github.com/DefectDojo/django-DefectDojo/tree/dev/docs as part of this PR.
  • Model changes must include the necessary migrations in the dojo/db_migrations folder.
  • Add applicable tests to the unit tests.
  • Add the proper label to categorize your PR.

Extra information

Please clear everything below when submitting your pull request, it's here purely for your information.

Moderators: Labels currently accepted for PRs:

  • Import Scans (for new scanners/importers)
  • enhancement
  • performance
  • feature
  • bugfix
  • maintenance (a.k.a chores)
  • dependencies
  • New Migration (when the PR introduces a DB migration)
  • settings_changes (when the PR introduces changes or new settings in settings.dist.py)

Contributors: Git Tips

Rebase on dev branch

If the dev branch has changed since you started working on it, please rebase your work after the current dev.

On your working branch mybranch:

git rebase dev mybranch

In case of conflict:

 git mergetool
 git rebase --continue

When everything's fine on your local branch, force push to your myOrigin remote:

git push myOrigin --force-with-lease

To cancel everything:

git rebase --abort

Squashing commits

git rebase -i origin/dev
  • Replace pick by fixup on the commits you want squashed out
  • Replace pick by reword on the first commit if you want to change the commit message
  • Save the file and quit your editor

Force push to your myOrigin remote:

git push myOrigin --force-with-lease

@github-actions github-actions bot added the helm label Oct 23, 2025
@carlosmt86 carlosmt86 force-pushed the feat/chart_hpa_pdb_13391 branch 5 times, most recently from 59e977a to 6ad7153 Compare October 23, 2025 14:31
@github-actions github-actions bot added the docs label Oct 23, 2025
@carlosmt86 carlosmt86 force-pushed the feat/chart_hpa_pdb_13391 branch from 6ad7153 to a12e4c1 Compare October 23, 2025 14:47
@Maffooch Maffooch requested review from kiblik and rossops October 23, 2025 16:47
@carlosmt86 carlosmt86 force-pushed the feat/chart_hpa_pdb_13391 branch 2 times, most recently from b402cbc to 8916e76 Compare October 24, 2025 08:02
@valentijnscholten valentijnscholten added this to the 2.52.0 milestone Oct 24, 2025
- Add PodDisruptionBudget for Django pods
- Add HorizontalPodAutoscaler for Django pods
- Add PodDisruptionBudget for Celery Beat pods
- Add HorizontalPodAutoscaler for Celery Beat pods
- All resources default to disabled (enabled: false)
- Configurable via values.yaml

Fixes DefectDojo#13391
@carlosmt86 carlosmt86 force-pushed the feat/chart_hpa_pdb_13391 branch from 8916e76 to feeec15 Compare October 24, 2025 09:57
@rossops
Copy link
Collaborator

rossops commented Oct 24, 2025

We should also strongly consider adding terminationGracePeriodSeconds to the django and definitely the celery-worker deployments with higher than the default 30(s) value. Using the default scale down behavior may not leave enough time for those jobs to finish after getting SIGTERM. I'd recommend 60 for django and 300 for celery-worker (largely based on my own usage).

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.

Fully agree with @rossops's comments

@carlosmt86 carlosmt86 requested a review from kiblik October 30, 2025 10:59
@carlosmt86 carlosmt86 requested a review from rossops October 30, 2025 10:59
@carlosmt86 carlosmt86 requested a review from rossops October 31, 2025 10:19
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.

A couple of small questions/suggestions (see comments).
Plus, can you add a description to https://github.com/DefectDojo/django-DefectDojo/blob/dev/helm/defectdojo/Chart.yaml#L37 (it will fix the linter).
The rest looks good to me.

@carlosmt86 carlosmt86 requested a review from kiblik November 3, 2025 08:44
@github-actions
Copy link
Contributor

github-actions bot commented Nov 3, 2025

This pull request has conflicts, please resolve those before we can evaluate the pull request.

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.

Approvved

@carlosmt86 carlosmt86 requested a review from kiblik November 7, 2025 08:51
@github-actions
Copy link
Contributor

github-actions bot commented Nov 7, 2025

Conflicts have been resolved. A maintainer will review the pull request shortly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants