Coder Social home page Coder Social logo

k8s-ei-operator's Introduction

k8s-ei-operator - Native support for Kubernetes Ecosystem with WSO2 Micro Integrator

The k8s-ei-operator allows you to deploy your integration into Kuberntes environment build on top of WSO2 Enterprise Integrator Tooling.

Defining an “Integration”

An integration is self-contained and independently deployable integration scenario composed with an arbitrary set of EI constructs which directly maps to a business capability.

An integration scenario could divide into the following three categories.

  • Synchronous service which may communicate with other systems
  • Asynchronous message Consumer/Producer
  • A periodically invoked pre-defined integration (e.g. Tasks)

Getting started

The k8s-ei-operator built with operator-sdk v0.7.0 and supported in the following environment.

  • Kubernetes cluster and client v1.11+

Install k8s-ei-operator

Standard mode

  1. Create the folder structure $GOPATH/src/github.com/wso2 if not available and clone k8s-ei-operator git repo

    git clone https://github.com/wso2/k8s-ei-operator.git
    
  2. Change directory to k8s-ei-operator

    cd $GOPATH/src/github.com/wso2/wso2/k8s-ei-operator
    
  3. Setup Service Account

    kubectl create -f deploy/service_account.yaml
    
  4. Setup RBAC

    kubectl create -f deploy/role.yaml
    kubectl create -f deploy/role_binding.yaml
    
  5. Deploy integration CustomResourceDefinition into Kubernetes cluster to understand custom resource type

    kubectl create -f deploy/crds/integration_v1alpha1_integration_crd.yaml
    
  6. Deploy the k8s-ei-operator

    kubectl create -f deploy/operator.yaml
    
  7. Deploy sample integration to start WSO2 micro integrator runtime which having 'User Info' API

    kubectl apply -f deploy/crds/user_mgt_demo_integration.yaml
    
  8. List the deployed integration

    kubectl get integration
    
  9. Invoke the User Info API once STATUS becomes Running

    i. Port forward

    kubectl port-forward service/user-mgt-demo-integration-service 8290:8290
    

    ii. Invoke the API

    curl http://localhost:8290/userInfo/users
    

Development mode

  1. Check out and install the operator-sdk CLI

  2. Install minikube and start Kubernetes cluster

  3. Create the folder structure $GOPATH/src/github.com/wso2 if not available and clone k8s-ei-operator git repo

    git clone https://github.com/wso2/k8s-ei-operator.git
    
  4. Change directory to k8s-ei-operator

    cd $GOPATH/src/github.com/wso2/wso2/k8s-ei-operator
    
  5. Deploy integration CustomResourceDefinition into Kubernetes cluster to understand custom resource type

    kubectl create -f deploy/crds/integration_v1alpha1_integration_crd.yaml
    
  6. Run the operator code as a Go program outside the Kubernetes cluster

    operator-sdk up local
    
  7. Deploy sample integration to start WSO2 micro integrator runtime which having 'User Info' API

    kubectl apply -f deploy/crds/user_mgt_demo_integration.yaml
    
  8. List the deployed integration

    kubectl get integration
    
  9. Invoke the User Info API once STATUS becomes Running

    i. Port forward

    kubectl port-forward service/er-mgt-demo-integration-service 8290:8290
    

    ii. Invoke the API

    curl http://localhost:8290/services/userInfo/users
    

Developer Workflow

developer-workflow

k8s-ei-operator's People

Contributors

a5anka avatar indikasampath2000 avatar maheshika avatar sanojpunchihewa avatar

Watchers

 avatar  avatar

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.