Commit 3dd45927 authored by Marco Lorini's avatar Marco Lorini
Browse files

2020-10-06 ML: add readme installation section

parent be367523
......@@ -75,3 +75,64 @@ switch context:
```
$ kubectl config use-context <context-name>
```
## Installation
### KubeFed client (kubefedctl)
To install the KubeFed client follow the below command in your local machine:
```
$ VERSION=0.2.0-alpha.1
$ OS=linux
$ ARCH=amd64
$ curl -LO https://github.com/kubernetes-sigs/kubefed/releases/download/v${VERSION}/kubefedctl-${VERSION}-${OS}-${ARCH}.tgz
$ tar -zxvf kubefedctl-*.tgz
$ chmod u+x kubefedctl
$ sudo mv kubefedctl /usr/local/bin/ # make sure the location is in the PATH
```
**N.B.**: the versions we tested are: 0.1.0-rc6 and 0.2.0-alpha.1, you can try the latest version.
### KubeFed server (Control Plane)
To install the Controll Plane, switch to the host context and configuring the RBAC role for Helm (in this case we use Helm v2):
```
$ cat << EOF | kubectl apply -f -
apiVersion: v1
kind: ServiceAccount
metadata:
name: tiller
namespace: kube-system
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
name: tiller
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: cluster-admin
subjects:
- kind: ServiceAccount
name: tiller
namespace: kube-system
EOF
```
helm init command:
```
$ helm init --service-account tiller
```
Now it is possible install the Control Plane on the Host Cluster:
```
$ helm repo add kubefed-charts https://raw.githubusercontent.com/kubernetes-sigs/kubefed/master/charts
$ helm install kubefed-charts/kubefed --name kubefed --version=0.2.0-alpha.1 --namespace kube-federation-system
```
**N.B.**: use the same version for client and server.
**N.B.**: in this way the Control Plane can find Federated resources in each namespace, to limit this action in a specific namespace add the parameter `--set global.scope=Namespaced`.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment