-
Notifications
You must be signed in to change notification settings - Fork 3
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
feat: introduces a new --cidr
command line flag
#1324
Open
ricardomaraschini
wants to merge
17
commits into
main
Choose a base branch
from
ricardomaraschini/sc-113112/introduce-new-cidr-flag-where-the-cidr-is
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
feat: introduces a new --cidr
command line flag
#1324
ricardomaraschini
wants to merge
17
commits into
main
from
ricardomaraschini/sc-113112/introduce-new-cidr-flag-where-the-cidr-is
+379
−23
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This PR has been released (on staging) and is available for download with a embedded-cluster-smoke-test-staging-app license ID. Online Installer:
Airgap Installer (may take a few minutes before the airgap bundle is built):
Happy debugging! |
ricardomaraschini
force-pushed
the
ricardomaraschini/sc-113112/introduce-new-cidr-flag-where-the-cidr-is
branch
2 times, most recently
from
October 16, 2024 12:28
98d2d6e
to
7cd2f30
Compare
these are going to be replaces by the new --cidr flag.
adds the --cidr flag and makes sure it is valid an at least a /16 subnet.
return an error if the cidr range is not private.
created function to split network cidr in half. we plan to use half for the pod network and the other half for the service network.
forward down the provided cidr to the k0s config. this commit also changes the functions that automatically sets the no proxy env var.
the new default cidr is different than the old one so some expectations need to be updated.
users are supposed to choose one or the other. if --cidr is present then users can't use --pod-cidr or --service-cidr.
store cidr in the runtimeconfig.
a new field was added to the runtime config spec object.
if during the installation --cidr was used then the restore message should inform users to use --cidr instead of --pod-cidr and --service-cidr this annotation isn't yet in the kots code but it will be as a follow up to this pr.
we won't use it anymore.
we wont be preserving the cidr in the cluster anymore.
we will need a function to verify if two networks are adjacent to each other and if they are, we will merge them into a single network.
ricardomaraschini
force-pushed
the
ricardomaraschini/sc-113112/introduce-new-cidr-flag-where-the-cidr-is
branch
from
October 16, 2024 18:55
6c4d607
to
a0d1087
Compare
if pod and svc networks are adjacent and with the same size we instruct the user to use --cidr instead of --pod-cidr and --service-cidr.
this is a remeniscent commit to remove old code that is no longer used
no-proxy should contain the custom cidr provided by the user.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What this PR does / why we need it:
This commit introduces the
--cidr
flag. This flag is meant to replace the--pod-cidr
and--service-cidr
flags (these are now hidden). When provided--cidr
must be equal or larger than a/16
and half of the IPs go to the pod network while the other half goes to the service network.The default value for
--cidr
is defined ask0sv1beta1.DefaultNetwork().PodCIDR
("10.244.0.0/16") resulting in pods getting the10.244.0.0/17
and services getting the10.244.128.0/17
network addresses.Does this PR require a test?
Does this PR require a release note?