Giter VIP home page Giter VIP logo

Comments (7)

rohanKanojia avatar rohanKanojia commented on June 3, 2024 2

I see. We would need to add support for these resources.

As a workaround, you can try generating POJOs for OVN CRDs using Fabric8 Java Generator

from kubernetes-client.

rohanKanojia avatar rohanKanojia commented on June 3, 2024 2

@lherman-vd : It would be nice if you could provide some early feedback now that the functionality has been merged. I've created a demo project showcasing OVN networking extension.

After the nightly SNAPSHOT build, you should be able to access k8s.ovn.org/v1 resources by adding this dependency . You would need to configure your project to use SNAPSHOTs.
User would need to add this dependency in order to use this extension:

    <dependency>
      <groupId>io.fabric8</groupId>
      <artifactId>open-virtual-networking-client</artifactId>
      <version>${fabric8.version}</version>
    </dependency>

Here is an example of sample usage:

    try (OpenVirtualNetworkingClient ovnClient = new KubernetesClientBuilder().build().adapt(OpenVirtualNetworkingClient.class)) {
      EgressFirewall egressFirewall = new EgressFirewallBuilder()
          .withNewMetadata()
          .withName("default")
          // ...
          .build();
      egressFirewall = ovnClient.v1().egressFirewalls().resource(egressFirewall).serverSideApply();

      egressFirewall = ovnClient.v1().egressFirewalls().resource(egressFirewall).get();
      System.out.println(egressFirewall.getMetadata().getName() + " Created");
    }

from kubernetes-client.

lherman-vd avatar lherman-vd commented on June 3, 2024 1

Apologies, I was on holiday the past few weeks.
Thank you for working on it 🎉 , I'll test the integration in our project asap.

from kubernetes-client.

rohanKanojia avatar rohanKanojia commented on June 3, 2024

Is this OVN API enabled in OpenShift by default? Do I have to install some operator to add these resources? I'm not able to access these on OpenShift 4.13.12 (CRC).

from kubernetes-client.

lherman-vd avatar lherman-vd commented on June 3, 2024

Our OpenShift rep recommended us to directly enable the OVN api when we starting building a new cluster, I think the migration process for existing clusters is detailed here: https://docs.openshift.com/container-platform/4.12/networking/ovn_kubernetes_network_provider/migrate-from-openshift-sdn.html

from kubernetes-client.

manusa avatar manusa commented on June 3, 2024

Is this OVN API enabled in OpenShift by default? Do I have to install some operator to add these resources? I'm not able to access these on OpenShift 4.13.12 (CRC).

Could you please verify if by using the cluster bot to start an OVN variant cluster these types are enabled?

from kubernetes-client.

rohanKanojia avatar rohanKanojia commented on June 3, 2024

Umm, yes I can see OVN types when I create a cluster using cluster bot:

adminpolicybasedexternalroutes        apbexternalroute    k8s.ovn.org/v1                                false        AdminPolicyBasedExternalRoute
egressfirewalls                                           k8s.ovn.org/v1                                true         EgressFirewall
egressips                             eip                 k8s.ovn.org/v1                                false        EgressIP
egressqoses                                               k8s.ovn.org/v1                                true         EgressQoS
egressservices                                            k8s.ovn.org/v1                                true         EgressService

from kubernetes-client.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.