pgw-key

command
v1.0.1-0...-3c4f842 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 16, 2017 License: MIT Imports: 7 Imported by: 0

README

Overview

pgw-key is a helper utility for managing Polymur-gateway API key registration in Consul.

Installation

Requires Go 1.6

  • go get -u github.com/jamiealquiza/polymur/...
  • go install github.com/jamiealquiza/polymur/cmd/util/pgw-key
  • Binary will be found at $GOPATH/bin/pgw-key

Usage

$ ./pgw-key 
Commands ('pgw-key <command>' for help):
	list
	create
	regen
	delete

Example

Create a test key
% ./pgw-key create test
Successfully registered test with key 0a8208f91d178f2b634fc0f6
$ ./pgw-key list all
test: 0a8208f91d178f2b634fc0f6
Key sync'd in Polymur-gateway
2016/08/02 14:21:33 Running API key sync
2016/08/02 14:21:33 API keys refreshed: 1 new, 0 removed
Running Polymur-proxy with the test key
$ ./polymur-proxy -gateway="https://localhost:443" -cert="/path/to/cert.pem"  -api-key="0a8208f91d178f2b634fc0f6"
2016/08/02 14:21:35 ::: Polymur-proxy :::
2016/08/02 14:21:35 Pinging gateway https://localhost:443
2016/08/02 14:21:35 Connection to gateway https://localhost:443 successful
Key validated by the gateway
2016/08/02 14:21:35 [client 127.0.0.1:52647] key for test is valid

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL