kwsk icon indicating copy to clipboard operation
kwsk copied to clipboard

how to get auth token ?

Open debianmaster opened this issue 7 years ago • 5 comments

i did

$ ISTIO=$(minikube ip):$(kubectl get svc knative-ingressgateway -n istio-system -o 'jsonpath={.spec.ports[?(@.port==80)].nodePort}')
$ go run ./cmd/kwsk-server/main.go --port 8080 --istio $ISTIO
2018/10/16 23:35:09 Serving kwsk at http://127.0.0.1:8080

Im getting this.

$ wsk action list --insecure
error: Unable to obtain the list of actions for namespace 'default': The connection failed, or timed out. (HTTP status code 401)
Run 'wsk --help' for usage.

debianmaster avatar Oct 16 '18 15:10 debianmaster

Hi,

I followed README instructions, invoked:

curl http://127.0.0.1:8080/api/v1/namespaces/foo/actions and I get: {"code":401,"message":"unauthenticated for invalid credentials"} Thanks.

aviweit avatar Dec 24 '18 15:12 aviweit

Keys have to be added to the interface - if this is a standard openwhisk deployment, you can populate the couchdb instance with keys. There is a tool for doing this called wskadmin that may be useful for this https://github.com/apache/incubator-openwhisk/tree/master/tools/admin.

rabbah avatar Dec 24 '18 15:12 rabbah

It works for me now after passing AUTH to wsk CLI (e.g. via ~/.wskprops). I can create and invoke the hello action. I am using latest wsk CLI.

Perhaps README file can be updated with the possible need of adding AUTH. The issue can be closed from my side.

aviweit avatar Dec 27 '18 08:12 aviweit

Is there identity management with this setup? Is there a default AUTH?

Zee-Khan avatar Mar 26 '19 22:03 Zee-Khan

Just as a note, we haven't maintained this kwsk experiment for quite some time now. It's not officially part of Apache OpenWhisk. But no, I don't think there was any specific identity management here.

bbrowning avatar Mar 27 '19 21:03 bbrowning