Deploy Sample Function

  • Apply function manifest, and check running states

    $ kubectl apply -f http-trigger.yaml
    function.core.openfunction.io/sample-node-http-trigger created
    
    $ kubectl get fn
    NAME                         BUILDSTATE   SERVINGSTATE   BUILDER   SERVING         URL                                                         AGE
    sample-node-http-trigger     Skipped      Running                  serving-7d75d   http://openfunction.io/default/sample-node-http-trigger     6d
    
    $ kubectl get deploy
    NAME                                       READY   UP-TO-DATE   AVAILABLE   AGE
    ...
    serving-7d75d-ksvc-xn768-v200-deployment   0/0     0            0           6d14h
    ...

Knative runtime would autoscale the deployment replica to 0, if no incoming request for a period of time.