Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support OAuth authentication #45

Open
kkhamruddin-pk opened this issue Aug 2, 2018 · 4 comments
Open

Support OAuth authentication #45

kkhamruddin-pk opened this issue Aug 2, 2018 · 4 comments

Comments

@kkhamruddin-pk
Copy link

Am unable to run chaosmonkey commands. Below is the error message am receiving.

ubuntu@ip-172-33-1-131:~$ chaosmonkey config my-aws-account
invalid character '<' looking for beginning of value
json unmarshal failed
github.com/Netflix/chaosmonkey/spinnaker.fromJSON
/home/ubuntu/chaos/src/github.com/Netflix/chaosmonkey/spinnaker/fromjson.go:99
github.com/Netflix/chaosmonkey/spinnaker.Spinnaker.Get
/home/ubuntu/chaos/src/github.com/Netflix/chaosmonkey/spinnaker/config.go:51
github.com/Netflix/chaosmonkey/spinnaker.(*Spinnaker).Get
:1
github.com/Netflix/chaosmonkey/command.DumpConfig
/home/ubuntu/chaos/src/github.com/Netflix/chaosmonkey/command/dumpconfig.go:27
github.com/Netflix/chaosmonkey/command.Execute
/home/ubuntu/chaos/src/github.com/Netflix/chaosmonkey/command/chaosmonkey.go:327
main.main
/home/ubuntu/chaos/src/github.com/netflix/chaosmonkey/cmd/chaosmonkey/main.go:35
runtime.main
/usr/lib/go-1.6/src/runtime/proc.go:188
runtime.goexit
/usr/lib/go-1.6/src/runtime/asm_amd64.s:1998

Here is my chaosmonkey.toml

ubuntu@ip-172-33-1-131:~$ cat /etc/chaosmonkey/chaosmonkey.toml
[chaosmonkey]
enabled = true
schedule_enabled = true
leashed = false
accounts = [ "my-aws-account", "my-azure-account", "my-gce-account", "my-k8s-v2-account", "k8s-v2-azure-account" ]

time_zone = "UTC"

[database]
host = "prl-mysql.exmps.com"
name = "chaosmonkey"
user = "chaosmonkey"
encrypted_password = "test@123"

[spinnaker]
endpoint = "http://spinnaker.exmps.com:8084"

here is my go version:

$ go version
go version go1.10.3 linux/amd64

Can someone please help?

@kkhamruddin-pk
Copy link
Author

Never mind. Have resolved this issue now. The issue is with the chaosmonkey reaching to spinnaker, wherein spinnaker has oauth authentication. I have disabled oauth authentication for spinnaker for time being, then it got work.

Guys,
Is there a way where we can make chaos work though we have spinnaker oauth authentication enabled???

@lorin lorin changed the title Unable to run chaosmonkey commands (invalid character '<' looking for beginning of value json unmarshal failed) Support OAuth authentication Aug 3, 2018
@lorin
Copy link
Contributor

lorin commented Aug 3, 2018

Chaos Monkey currently only supports client certificates (PKCS12 or X509) for authentication. We'll certainly consider merging in this functionality if somebody in the community submits a PR. However, because Netflix doesn't use OAuth internally, we're unlikely to add this functionality ourselves.

@banghuaji
Copy link

spinnaker use ldap for authn,i have the same issue

@banghuaji
Copy link

[root@localhost ~]# chaosmonkey account my-k8s-v2-account
ERROR: Could not retrieve id for account: my-k8s-v2-account. Reason: could not parse body of http://192.168.105.4:8084/credentials/prod as json, body: , error: unexpected end of JSON input
[root@localhost ~]# chaosmonkey account my-k8s-v2-accountt
ERROR: Could not retrieve id for account: my-k8s-v2-accountt. Reason: could not parse body of http://192.168.105.4:8084/credentials/my-k8s-v2-accountt as json, body: , error: unexpected end of JSON input

when i use my-k8s-v2-account ,the request turn to ' http://192.168.105.4:8084/credentials/prod '

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants