-
Notifications
You must be signed in to change notification settings - Fork 4
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
bond1 #57
bond1 #57
Conversation
if self.ipv4pub: | ||
# Only needed when a public ip is used, otherwise private ip is | ||
# already set and no special routes are needed. | ||
for bond in self.network.bonds.keys(): |
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.
by default python loops through the keys. so you shouldn't need to use .keys()
) | ||
|
||
if self.ipv4pub: |
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.
this should only be defined on the bond0 interface. otherwise it would define the public ip for both bond0 and bond1 which wouldn't work
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.
Should I un-template these files and set them back to just bond0?
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.
I guess the better question, will they ever need to be a different bond in the future, or is it okay to just leave them at bond0?
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.
i like that it supports multiple, i think just changing it to if bond == 'bond0' and self.ipv4pub
and that should be good enough for now, maybe in the future we'll support more than just that
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.
Okay, can do!
Thanks for the feedback! I'll work on fixes for both of those. |
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.
Think this looks good, Can you also test this on an existing plan with 2+ bonds?
I can see some future possible issues if we get rid of the if self.ipv4pub and bond == "bond0":
where self.ipv4pub
always points to the same ip. But that's not an issue in the current state and can be handled if that is ever changed.
Testing n2.xl here: |
Everything looks good except package manager on centos_8, but that breaks on a normal install too. Gonna land it! |
Everything looks good except package manager on centos_8, but that's also broken on a normal install, I think some of the repos aren't up any more. Gonna merge. |
Set correct bond in interface files.