Create an Istio virtual service for OpenFaaS Gateway (replace example.com
with your domain):
apiVersion: networking.istio.io/v1alpha3
kind: VirtualService
metadata:
name: gateway
namespace: openfaas
spec:
hosts:
- "openfaas.example.com"
gateways:
- public-gateway.istio-system.svc.cluster.local
http:
- route:
- destination:
host: gateway
timeout: 30s
Save the above resource as of-virtual-service.yaml and then apply it:
kubectl apply -f ./of-virtual-service.yaml
Wait for OpenFaaS Gateway to come online:
watch curl -v https://openfaas.example.com/healthz
Save your credentials in faas-cli store:
echo $password | faas-cli login -g https://openfaas.example.com -u admin --password-stdin