Skip to content
This repository was archived by the owner on Jan 9, 2020. It is now read-only.

Commit 6cf635d

Browse files
foxishash211
authored andcommitted
Add instructions to find master URL (#169)
1 parent f414355 commit 6cf635d

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

docs/running-on-kubernetes.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,14 +55,23 @@ being contacted at `api_server_url`. If no HTTP protocol is specified in the URL
5555
setting the master to `k8s://example.com:443` is equivalent to setting it to `k8s://https://example.com:443`, but to
5656
connect without SSL on a different port, the master would be set to `k8s://http://example.com:8443`.
5757

58+
59+
If you have a Kubernetes cluster setup, one way to discover the apiserver URL is by executing `kubectl cluster-info`.
60+
61+
> kubectl cluster-info
62+
Kubernetes master is running at http://127.0.0.1:8080
63+
64+
In the above example, the specific Kubernetes cluster can be used with spark submit by specifying
65+
`--master k8s://http://127.0.0.1:8080` as an argument to spark-submit.
66+
5867
Note that applications can currently only be executed in cluster mode, where the driver and its executors are running on
5968
the cluster.
6069

6170
### Dependency Management and Docker Containers
6271

6372
Spark supports specifying JAR paths that are either on the submitting host's disk, or are located on the disk of the
6473
driver and executors. Refer to the [application submission](submitting-applications.html#advanced-dependency-management)
65-
section for details. Note that files specified with the `local` scheme should be added to the container image of both
74+
section for details. Note that files specified with the `local://` scheme should be added to the container image of both
6675
the driver and the executors. Files without a scheme or with the scheme `file://` are treated as being on the disk of
6776
the submitting machine, and are uploaded to the driver running in Kubernetes before launching the application.
6877

0 commit comments

Comments
 (0)