Advanced Setup
Advanced setup guide for Fission installation
Welcome! This guide will get you up and running with Fission on a Kubernetes cluster.
First, let’s ensure you have the Kubernetes CLI and Helm installed and ready. If you already have helm, skip ahead to the fission install.
If you cannot (or don’t want to) use Helm, there is an alternative installation method possible; see installing without Helm.
If you don’t have a Kubernetes cluster, here’s a official guide to set one up.
Fission requires Kubernetes 1.9 or higher
Kubectl is a command line interface for running commands against Kubernetes clusters, visit here to see how to install it.
See how to setup config correctly on different platforms Next, ensure you have access to a cluster. Do this by using kubectl to check your Kubernetes version:
$ kubectl version
Helm is an installer for Kubernetes. If you already use helm, skip to the next section.
To install helm, first you’ll need the helm CLI. Visit here to see how to install it.
You can skip the following and head over Fission installation if you’re using Helm v3.
Next, install the Helm server on your Kubernetes cluster. Before you do that, you have to give helm’s server privileges to install software on your cluster.
For example, you can use the following steps to install helm using a dedicated service account with full cluster admin privileges.
$ kubectl create serviceaccount --namespace kube-system tiller
$ kubectl create clusterrolebinding tiller-cluster-rule \
--clusterrole=cluster-admin --serviceaccount=kube-system:tiller
$ helm init --service-account tiller
Or, if your cluster is already set up with a permissive service account (this varies by version and how your Kubernetes was installed), you can simply do:
$ helm init
fission-all (Recommend)
fission-core
Following, we will use fission-all
to demonstrate how to install Fission.
List of all supported configurations for the charts fission-all
and fission-core
can be found here.
The environment like Minikube that doesn’t support service type LoadBalancer
should use NodePort
instead.
You can check it by creating a service with LoadBalancer type to see if it shows <pending>
and never changes.
$ kubectl get svc
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
router LoadBalancer 10.109.61.85 <pending> 80:31972/TCP 25h
$ helm install --name fission --namespace fission \
--set serviceType=NodePort,routerServiceType=NodePort \
https://github.com/fission/fission/releases/download/1.11.2/fission-all-1.11.2.tgz
$ export FISSION_NAMESPACE="fission"
$ kubectl create namespace $FISSION_NAMESPACE
$ helm install --namespace $FISSION_NAMESPACE --name-template fission \
https://github.com/fission/fission/releases/download/1.11.2/fission-all-1.11.2.tgz
Please visit OpenShift for more detailed information.
$ helm install --name fission --namespace fission \
--set serviceType=NodePort,routerServiceType=NodePort,logger.enableSecurityContext=true,prometheus.enabled=false \
https://github.com/fission/fission/releases/download/1.11.2/fission-all-1.11.2.tgz
$ export FISSION_NAMESPACE="fission"
$ kubectl create namespace $FISSION_NAMESPACE
$ helm install --namespace $FISSION_NAMESPACE --name-template fission \
--set serviceType=NodePort,routerServiceType=NodePort,logger.enableSecurityContext=true,prometheus.enabled=false \
https://github.com/fission/fission/releases/download/1.11.2/fission-all-1.11.2.tgz
The serviceType variable allows configuring the type of Kubernetes
service outside the cluster. You can use ClusterIP
if you don’t
want to expose anything outside the cluster.
See how to add token to kubeconfig if you’re not able to connect to cluster.
$ helm install --name fission --namespace fission \
https://github.com/fission/fission/releases/download/1.11.2/fission-all-1.11.2.tgz
$ export FISSION_NAMESPACE="fission"
$ kubectl create namespace $FISSION_NAMESPACE
$ helm install --namespace $FISSION_NAMESPACE --name-template fission \
https://github.com/fission/fission/releases/download/1.11.2/fission-all-1.11.2.tgz
Please visit OpenShift for more detailed information.
$ helm install --name fission --namespace fission \
--set logger.enableSecurityContext=true,prometheus.enabled=false \
https://github.com/fission/fission/releases/download/1.11.2/fission-all-1.11.2.tgz
$ export FISSION_NAMESPACE="fission"
$ kubectl create namespace $FISSION_NAMESPACE
$ helm install --namespace $FISSION_NAMESPACE --name-template fission \
--set logger.enableSecurityContext=true,prometheus.enabled=false \
https://github.com/fission/fission/releases/download/1.11.2/fission-all-1.11.2.tgz
This method uses kubectl apply
to install Fission. You can edit the
YAML file before applying it to your cluster, if you want to change
anything in it. Create namespace for fission installation.
$ kubectl create namespace fission
- If you want to install in another namespace, please consider to use
helm
.
Choose one of the following commands to run:
fission-all
or fission-core
. Here, we use fission-all
to demonstrate the installation.$ kubectl apply -f \
https://github.com/fission/fission/releases/download/1.11.2/fission-all-1.11.2.yaml
$ kubectl apply -f \
https://github.com/fission/fission/releases/download/1.11.2/fission-all-1.11.2-minikube.yaml
Please visit OpenShift for more detailed information.
$ kubectl -n fission apply -f \
https://github.com/fission/fission/releases/download/1.11.2/fission-core-1.11.2-openshift.yaml
$ curl -Lo fission https://github.com/fission/fission/releases/download/1.11.2/fission-cli-osx \
&& chmod +x fission && sudo mv fission /usr/local/bin/
$ curl -Lo fission https://github.com/fission/fission/releases/download/1.11.2/fission-cli-linux \
&& chmod +x fission && sudo mv fission /usr/local/bin/
Finally, you’re ready to use Fission!
$ fission env create --name nodejs --image fission/node-env:latest
$ curl -LO https://raw.githubusercontent.com/fission/fission/master/examples/nodejs/hello.js
$ fission function create --name hello --env nodejs --code hello.js
$ fission function test --name hello
Hello, world!
For more language tutorials, visit Language.
If something went wrong, we’d love to help – please drop by the slack channel and ask for help.
Check out the examples for some example functions.
Advanced setup guide for Fission installation
Upgrade guide for Fission installation
Environment variables used by Fission CLI
OpenShift specific setup
Installation guide for offline on-premise.
Docker Desktop specific setup