-
Notifications
You must be signed in to change notification settings - Fork 2.9k
17686 config option for disk divider #18011
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
17686 config option for disk divider #18011
Conversation
|
This PR has been automatically marked as stale because it has not had recent activity. It will be closed automatically if no further action is taken. |
|
Would love to see this merged, running behind on v4.0 because of dependencies on netbox. |
|
Would love to see this merged, too. |
|
Can you rebase to main? |
arthanson
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These also need to be added to the documentation, configuration/miscellaneous.md
….com/Haeki/netbox into 17686-config_option_for_disk_divider
|
@Haeki is this ready for re-review? If so please toggle the re-request review (spinner) in the upper right next to my name. |
Fixes: #17686 Ability to select disk divider
I added two new config options to specify the divider used to calculate the disk and ram sizes in different units.
The default value is 1000 but can be changed to 1024 to get GiB instead of GB.
Those config values are used in the
humanize_megabytesmethod. I split this method into two separate methods, one for RAM and one for disk values. Additionally I added the disk config value to the disk migration so that users with GiB values get them converted to MiB.I tested the changes in my local environment and noticed no problems.
I'm open for feedback and I also didn't include any tests yet.