Skip to content

DNM | WIP: PoC of sticky IPs for Kubernetes entities#377

Closed
maiqueb wants to merge 1 commit into
k8snetworkplumbingwg:masterfrom
maiqueb:sticky-ips
Closed

DNM | WIP: PoC of sticky IPs for Kubernetes entities#377
maiqueb wants to merge 1 commit into
k8snetworkplumbingwg:masterfrom
maiqueb:sticky-ips

Conversation

@maiqueb

@maiqueb maiqueb commented Aug 14, 2023

Copy link
Copy Markdown
Collaborator

What this PR does / why we need it:
This is a proof of concept of implementing sticky IP allocations for whereabouts.

Any interested party can use whereabouts to have persistent IP allocations across their workload lifecycle - e.g. KubeVirt VMs.

You indicate this whereabouts build you want to have persistent IPs for a certain allocation by specifying which enitity owns the allocation - in our case, the allocations are asked for a KubeVirt VM. Thus, the pod must be templated w/ the required CNI args:

kubectl get pods virt-launcher-vm-rhel8-7fmb7 -ojsonpath="{ @.metadata.annotations.k8s\.v1\.cni\.cncf\.io\/networks }" | jq
[
  {
    "name": "whereabouts-conf",
    "namespace": "default",
    "interface": "pod16367aacb67",
    "cni-args": {
      "whereabouts.cni.cncf.io/ownerID": "8d9d6b85-49e1-4722-9b42-3348d8e9b9f6",
      "whereabouts.cni.cncf.io/ownerName": "vm-rhel8",
      "whereabouts.cni.cncf.io/ownerType": "VirtualMachine",
      "whereabouts.cni.cncf.io/ownerVersion": "kubevirt.io/v1"
    }
  }
]

We are using the OverlappingRangeIPReservation to block the IP allocations (it is its purpose at the end of the day ...) but the "real" proposal will probably add a new CRD for the same function.

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #

Special notes for your reviewer (optional):

@maiqueb maiqueb added the enhancement New feature or request label Aug 14, 2023
@maiqueb maiqueb requested a review from dougbtv as a code owner August 14, 2023 11:44
@maiqueb

maiqueb commented Aug 14, 2023

Copy link
Copy Markdown
Collaborator Author

/cc @oshoval @qinqon

Signed-off-by: Miguel Duarte Barroso <mdbarroso@redhat.com>
@github-actions

Copy link
Copy Markdown

This pull request has been automatically marked as stale because it has not had
recent activity. It will be closed if no further activity occurs. Thank you
for your contributions.

@github-actions github-actions Bot added the stale Issue or PR has become stale label Nov 28, 2025
@github-actions github-actions Bot closed this Dec 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request stale Issue or PR has become stale

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant