Knative Functions client API and CLI
Go to file
Luke K 12b45a3b1a
docs: configuration additions
2020-04-11 19:45:58 +00:00
appsody print command run when running with verbosity enabled 2020-04-11 19:31:28 +00:00
client core tests with mocks for pusher and deployer 2020-04-11 19:44:47 +00:00
cmd enable pusher and deployer in command 2020-04-11 19:45:05 +00:00
docker docker-based pusher implementation 2020-04-11 19:43:38 +00:00
k8s network and domain kube configs 2020-04-11 19:41:42 +00:00
kubectl kubectl-based deployer implementation 2020-04-11 19:43:59 +00:00
.gitignore Initial Commit 2020-03-04 14:36:41 +00:00
README.md docs: configuration additions 2020-04-11 19:45:58 +00:00
go.mod dependencies update 2020-04-11 19:45:29 +00:00
go.sum dependencies update 2020-04-11 19:45:29 +00:00
main.go Command improvements 2020-04-09 16:30:06 +00:00

README.md

faas

Function as a Service CLI

Requirements

Go 1.13+

Install

Build and install the resultant binary.

go install

Build

Build binary into the local directory.

go build

Usage

See help:

faas

Configuration

Knative Serving Network Configuraiton

Patch the Knative Network Config to enable subdomains:

kubectl apply -f ./k8s/config-network.yaml`

Patch the Knative Domains Config to set a default domain:

kubectl apply -f ./k8s/config-domain.yaml`

Public Container Registry and Namespace

Both the image registry and user/org namespace need to be defined either by using the --registry and --namespace flags on the create command, or by configuring as environment variables. For example to configure all images to be pushed to quay.io/alice, use:

export FAAS_REGISTRY=quay.io
export FAAS_NAMESPACE=alice

Examples

Create a new Function Service:

> mkdir -p example.com/www
> cd example.com/www
> faas create go
OK www.example.com
> curl https://www.example.com
OK