2024 Feb 22 10:43 AM - edited 2024 Feb 22 10:54 AM
Hello,
I was simply trying to deploy sample cap project to BTP CF (Trial) but every time it failed with deployment, with the following reason: Error: Authentication kind "jwt" configured, but no XSUAA instance bound to
I can see the error comes all the way from node_modules/@sap/cds/lib/auth/jwt-auth.js.
The project I created from template with minimal option I chose, and I didn't want to attach any security to my app. This works fine while testing locally but deploying it to BTP ending up with the above error.
Tried with some earlier versions of @Sisn/cds but no luck. Is this a known error?
Can someone kindly confirm? or may I am missing some basics!
- Thanks, Somnath
Request clarification before answering.
Not this is not a bug. This is the documented behavior. See authentication is enforced in production.
You may explicitly enable mocked strategy in production by adding the following to file .cdsrc.json
{
"requires": {
"auth": "mocked"
}
}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Dinu,
I have given the above into my .cdsrc.json, but still I'm getting the same error while executing the program
Error: Authentication kind "xsuaa" configured, but no XSUAA instance bound to application. Either bind an IAS instance, or switch to an authentication kind that does not require a binding.
at jwt_auth (/home/user/projects/MyHANAApp/node_modules/@sap/cds/lib/auth/jwt-auth.js:17:11) at auth_factory (/home/user/projects/MyHANAApp/node_modules/@sap/cds/lib/auth/index.js:46:61) at _instantiate (/home/user/projects/MyHANAApp/node_modules/@sap/cds/lib/srv/middlewares/index.js:49:12) at /home/user/projects/MyHANAApp/node_modules/@sap/cds/lib/srv/middlewares/index.js:13:13 at Array.map (<anonymous>) at Object.<anonymous> (/home/user/projects/MyHANAApp/node_modules/@sap/cds/lib/srv/middlewares/index.js:13:3) at Module._compile (/home/user/projects/MyHANAApp/lib/internal/modules/cjs/loader.js:1369:14) at Module._extensions..js (/home/user/projects/MyHANAApp/lib/internal/modules/cjs/loader.js:1427:10) at Module.load (/home/user/projects/MyHANAApp/lib/internal/modules/cjs/loader.js:1206:32) at Module._load (node:internal/modules/cjs/loader:1022:12) {stack: 'Error: Authentication kind "xsuaa" configured…ad (node:internal/modules/cjs/loader:1022:12)', message: 'Authentication kind "xsuaa" configured, but …cation kind that does not require a binding.'}
User | Count |
---|---|
82 | |
29 | |
9 | |
8 | |
7 | |
7 | |
7 | |
6 | |
6 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.