Merge pull request #63 from paypal/addSSLToExample
Add ssl to example client, misc doc fixes
This commit is contained in:
commit
800efccb31
3 changed files with 18 additions and 4 deletions
5
.github/PULL_REQUEST_TEMPLATE.md
vendored
5
.github/PULL_REQUEST_TEMPLATE.md
vendored
|
@ -1,11 +1,14 @@
|
||||||
|
<!--
|
||||||
-----------------------------------------
|
-----------------------------------------
|
||||||
## Please read instructions below ##
|
## Please read instructions below ##
|
||||||
|
|
||||||
Before submitting, please make sure you run a vagrant box running Aurora with the latest version shown in .auroraversion and run go test from the project root.
|
Before submitting, please make sure you run a vagrant box running Aurora with the latest version shown in .auroraversion and run go test from the project root.
|
||||||
|
|
||||||
To run an Aurora Vagrant image, follow the instructions here:
|
To run an Aurora Vagrant image, follow the instructions here:
|
||||||
http://aurora.apache.org/documentation/latest/getting-started/vagrant/
|
http://aurora.apache.org/documentation/latest/getting-started/vagrant/
|
||||||
|
|
||||||
|
## Answer the following questions: ##
|
||||||
|
-->
|
||||||
|
|
||||||
* Have you run goformat on the project before submitting?
|
* Have you run goformat on the project before submitting?
|
||||||
|
|
||||||
* Have you run go test on the project before submitting? Do all tests pass?
|
* Have you run go test on the project before submitting? Do all tests pass?
|
||||||
|
|
|
@ -12,8 +12,10 @@ library has been tested.
|
||||||
* [Using the sample client](docs/using-the-sample-client.md)
|
* [Using the sample client](docs/using-the-sample-client.md)
|
||||||
* [Leveraging the library](docs/leveraging-the-library.md)
|
* [Leveraging the library](docs/leveraging-the-library.md)
|
||||||
|
|
||||||
## To Do
|
## Projects using gorealis
|
||||||
* Create or import a custom transport that uses https://github.com/jmcvetta/napping to improve efficiency
|
|
||||||
|
* [australis](https://github.com/rdelval/australis)
|
||||||
|
|
||||||
## Contributions
|
## Contributions
|
||||||
Contributions are always welcome. Please raise an issue so that the contribution may be discussed before it's made.
|
Contributions are always welcome. Please raise an issue to discuss a contribution before it is made.
|
||||||
|
|
||||||
|
|
|
@ -31,6 +31,8 @@ import (
|
||||||
)
|
)
|
||||||
|
|
||||||
var cmd, executor, url, clustersConfig, clusterName, updateId, username, password, zkUrl, hostList, role string
|
var cmd, executor, url, clustersConfig, clusterName, updateId, username, password, zkUrl, hostList, role string
|
||||||
|
var caCertsPath string
|
||||||
|
var clientKey, clientCert string
|
||||||
|
|
||||||
var CONNECTION_TIMEOUT = 20000
|
var CONNECTION_TIMEOUT = 20000
|
||||||
|
|
||||||
|
@ -46,6 +48,9 @@ func init() {
|
||||||
flag.StringVar(&zkUrl, "zkurl", "", "zookeeper url")
|
flag.StringVar(&zkUrl, "zkurl", "", "zookeeper url")
|
||||||
flag.StringVar(&hostList, "hostList", "", "Comma separated list of hosts to operate on")
|
flag.StringVar(&hostList, "hostList", "", "Comma separated list of hosts to operate on")
|
||||||
flag.StringVar(&role, "role", "", "owner role to use")
|
flag.StringVar(&role, "role", "", "owner role to use")
|
||||||
|
flag.StringVar(&caCertsPath, "caCertsPath", "", "Path to CA certs on local machine.")
|
||||||
|
flag.StringVar(&clientCert, "clientCert", "", "Client certificate to use to connect to Aurora.")
|
||||||
|
flag.StringVar(&clientKey, "clientKey", "", "Client key to use to connect to Aurora.")
|
||||||
|
|
||||||
flag.Parse()
|
flag.Parse()
|
||||||
|
|
||||||
|
@ -102,6 +107,10 @@ func main() {
|
||||||
clientOptions = append(clientOptions, realis.SchedulerUrl(url))
|
clientOptions = append(clientOptions, realis.SchedulerUrl(url))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if clientKey != "" || clientCert != "" || caCertsPath != "" {
|
||||||
|
clientOptions = append(clientOptions, realis.Certspath(caCertsPath), realis.ClientCerts(clientKey, clientCert))
|
||||||
|
}
|
||||||
|
|
||||||
r, err = realis.NewRealisClient(clientOptions...)
|
r, err = realis.NewRealisClient(clientOptions...)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
fmt.Println(err)
|
fmt.Println(err)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue