Categorygithub.com/opencdk8s/cdk8s-aws-lb-controller-api-object-go/opencdk8scdk8sawslbcontrollerapiobject

# README

cdk8s-aws-lb-controller-api-object

Release npm version PyPI version npm

API Object for AWS Load Balancer Controller, powered by the cdk8s project and aws-load-balancer-controller 🚀

Overview

import { Construct } from 'constructs';
import { App, Chart, ChartProps } from 'cdk8s';
import { AWSLoadBalancerControllerObject } from '@opencdk8s/cdk8s-aws-lb-controller-api-object'


export class MyChart extends Chart {
  constructor(scope: Construct, id: string, props: ChartProps = { }) {
    super(scope, id, props);
    new AWSLoadBalancerControllerObject(this, 'example', {
      metadata: {
        annotations: {
          'kubernetes.io/ingress.class': 'alb',
        }
      },
      spec: {
        rules: [{
          host: "example.com",
          http: {
            paths: [{
              path: '/*',
              backend: {
                serviceName: 'helloworld-svc',
                servicePort: 80
              }
            }]
          }
        }]
      }
    })

    }
}

const app = new App();
new MyChart(app, 'example1');
app.synth();

Example cdk8s synth manifest as follows.

manifest.k8s.yaml
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
  annotations:
    kubernetes.io/ingress.class: alb
  name: example-c89c1904
spec:
  rules:
    - host: example.com
      http:
        paths:
          - backend:
              serviceName: helloworld-svc
              servicePort: 80
            path: /*


Installation

TypeScript

Use yarn or npm to install.

$ npm install @opencdk8s/cdk8s-aws-lb-controller-api-objects
$ yarn add @opencdk8s/cdk8s-aws-lb-controller-api-objects

Python

$ pip install cdk8s-aws-lb-controller-api-objects

Contribution

  1. Fork (link)

  2. Bootstrap the repo:

    yarn install # installs dependencies
    yarn projen
    
  3. Development scripts:

    CommandDescription
    yarn compileCompiles typescript => javascript
    yarn watchWatch & compile
    yarn testRun unit test & linter through jest
    yarn test -uUpdate jest snapshots
    yarn run packageCreates a dist with packages for all languages.
    yarn buildCompile + test + package
    yarn bumpBump version (with changelog) based on [conventional commits]
    yarn releaseBump + push to master
  4. Create a feature branch

  5. Commit your changes

  6. Rebase your local changes against the master branch

  7. Create a new Pull Request (use conventional commits for the title please)

Licence

Apache License, Version 2.0

Author

Hunter-Thompson

# Packages

Package jsii contains the functionaility needed for jsii packages to initialize their dependencies and themselves.

# Functions

No description provided by the author
Checks if `x` is a construct.
Renders a Kubernetes manifest for an ingress object.
Returns the `ApiObject` named `Resource` which is a child of the given construct.
Experimental.
Experimental.
Defines an "extentions" API object for AWS Load Balancer Controller - https://github.com/kubernetes-sigs/aws-load-balancer-controller.
Defines an "extentions" API object for AWS Load Balancer Controller - https://github.com/kubernetes-sigs/aws-load-balancer-controller.

# Structs

Experimental.
HTTPIngressPath associates a path regex with a backend.
HTTPIngressRuleValue is a list of http selectors pointing to backends.
IngressBackend describes all endpoints for a given service and port.
IngressRule represents the rules mapping the paths under a specified host to the related backend services.
IngressSpec describes the Ingress the user wishes to exist.
IngressTLS describes the transport layer security associated with an Ingress.
Initializer is information about an initializer that has not yet completed.
Initializers tracks the progress of initialization.
Status is a return value for calls that don't return other objects.
ListMeta describes metadata that synthetic resources must have, including lists and various status objects.
ManagedFieldsEntry is a workflow-id, a FieldSet and the group version of the resource that the fieldset applies to.
ObjectMeta is metadata that all persisted resources must have, which includes all objects users must create.
OwnerReference contains enough information to let you identify an owning object.
StatusCause provides more information about an api.Status failure, including cases when multiple errors are encountered.
StatusDetails is a set of additional properties that MAY be set by the server to provide additional information about a response.

# Interfaces

Experimental.
Experimental.