@@ -30,8 +30,10 @@ Optionally, your Kubernetes cluster should be configured with a Loadbalancer int
30
30
31
31
## Step One: Create namespace
32
32
33
+ Create the namespace by executing the following command using ` kubectl ` :
34
+
33
35
``` sh
34
- $ kubectl create -f examples/staging/spark/namespace-spark-cluster.yaml
36
+ kubectl create -f examples/staging/spark/namespace-spark-cluster.yaml
35
37
```
36
38
37
39
Now list all namespaces:
@@ -43,14 +45,14 @@ default <none> Active
43
45
spark-cluster name=spark-cluster Active
44
46
```
45
47
46
- To configure kubectl to work with our namespace, we will create a new context using our current context as a base:
48
+ To configure kubectl to work with our namespace, we will create a new context using our current context as a base with the following commands :
47
49
48
50
``` sh
49
- $ CURRENT_CONTEXT=$( kubectl config view -o jsonpath=' {.current-context}' )
50
- $ USER_NAME=$( kubectl config view -o jsonpath=' {.contexts[?(@.name == "' " ${CURRENT_CONTEXT} " ' ")].context.user}' )
51
- $ CLUSTER_NAME=$( kubectl config view -o jsonpath=' {.contexts[?(@.name == "' " ${CURRENT_CONTEXT} " ' ")].context.cluster}' )
52
- $ kubectl config set-context spark --namespace=spark-cluster --cluster=${CLUSTER_NAME} --user=${USER_NAME}
53
- $ kubectl config use-context spark
51
+ CURRENT_CONTEXT=$( kubectl config view -o jsonpath=' {.current-context}' )
52
+ USER_NAME=$( kubectl config view -o jsonpath=' {.contexts[?(@.name == "' " ${CURRENT_CONTEXT} " ' ")].context.user}' )
53
+ CLUSTER_NAME=$( kubectl config view -o jsonpath=' {.contexts[?(@.name == "' " ${CURRENT_CONTEXT} " ' ")].context.cluster}' )
54
+ kubectl config set-context spark --namespace=spark-cluster --cluster=${CLUSTER_NAME} --user=${USER_NAME}
55
+ kubectl config use-context spark
54
56
```
55
57
56
58
## Step Two: Start your Master service
@@ -279,7 +281,7 @@ If your Kubernetes cluster does not have a Loadbalancer integration, then we wil
279
281
Take the Zeppelin pod from before and port-forward the WebUI port:
280
282
281
283
``` console
282
- $ kubectl port-forward zeppelin-controller-ja09s 8080:8080
284
+ kubectl port-forward zeppelin-controller-ja09s 8080:8080
283
285
```
284
286
285
287
This forwards ` localhost ` 8080 to container port 8080. You can then find
0 commit comments