net-gateway-api

module
v0.28.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 10, 2021 License: Apache-2.0

README

Knative net-gateway-api

This component is ALPHA

GoDoc Go Report Card

net-gateway-api repository contains a KIngress implementation and testing for Knative integration with the Kubernetes Gateway API.

This work is still in early development, which means it's not ready for production, but also that your feedback can have a big impact. You can also find the tested Ingress and unavailable features here.

Getting started

  • Load tested environment versions
source ./hack/test-env.sh
  • Install Knative Serving
kubectl apply -f https://github.com/knative/serving/releases/latest/download/serving-crds.yaml
kubectl apply -f https://github.com/knative/serving/releases/latest/download/serving-core.yaml
  • Install net-gateway-api
ko apply -f config/
  • Then install Istio and its gateway resources:

NOTE You can find the Istio version to be installed in ./hack/test-env.sh.

curl -sL https://istio.io/downloadIstioctl | sh -
$HOME/.istioctl/bin/istioctl install -y

kubectl apply -f third_party/istio/gateway/
  • Configure Knative Serving to use the proper "ingress.class":
kubectl patch configmap/config-network \
  -n knative-serving \
  --type merge \
  -p '{"data":{"ingress.class":"gateway-api.ingress.networking.knative.dev"}}'
  • Configure Knative Serving to use the proper "ingress.class":
kubectl patch configmap/config-domain \
  -n knative-serving \
  --type merge \
  -p '{"data":{"127.0.0.1.nip.io":""}}'
  • (OPTIONAL) Deploy a sample hello world app:
cat <<-EOF | kubectl apply -f -
apiVersion: serving.knative.dev/v1
kind: Service
metadata:
  name: helloworld-go
spec:
  template:
    spec:
      containers:
      - image: gcr.io/knative-samples/helloworld-go
        env:
        - name: TARGET
          value: Go Sample v1
EOF
  • (OPTIONAL) For testing purposes, you can use port-forwarding to make requests to ingress from your machine:
kubectl port-forward  -n istio-system $(kubectl get pod -n istio-system -l "app=istio-ingressgateway" --output=jsonpath="{.items[0].metadata.name}") 8080:8080

curl -v -H "Host: helloworld-go.default.127.0.0.1.nip.io" http://localhost:8080

To learn more about Knative, please visit our Knative docs repository.

If you are interested in contributing, see CONTRIBUTING.md and DEVELOPMENT.md.

Directories

Path Synopsis
cmd
controller command
pkg
client/gatewayapi/clientset/versioned
This package has the automatically generated clientset.
This package has the automatically generated clientset.
client/gatewayapi/clientset/versioned/fake
This package has the automatically generated fake clientset.
This package has the automatically generated fake clientset.
client/gatewayapi/clientset/versioned/scheme
This package contains the scheme of the automatically generated clientset.
This package contains the scheme of the automatically generated clientset.
client/gatewayapi/clientset/versioned/typed/apis/v1alpha1
This package has the automatically generated typed clients.
This package has the automatically generated typed clients.
client/gatewayapi/clientset/versioned/typed/apis/v1alpha1/fake
Package fake has the automatically generated clients.
Package fake has the automatically generated clients.
ha

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL