on ‎2024 Mar 09 8:37 AM
Hi Everyone
We are trying to deploy a project with db module having a HANA calculation view which further being consumed to create a cds based service using srv node js module. While it is working when we build and test locally, the deployment is failing with below error. Can anyone please guide me in fixing the issue? Please find the package.json (project level and srv module level) and MTA.yaml files in the attachments
/hana/shared/<SID>/xs/app_working/<SYSTEM ALIAS>/executionroot/8db36740-9455-4ff1-aee3-b9c51994fd5f/startCommand: line 8: exec: /hana/shared/<SID>/xs/app_working/<SYSTEM_ALIAS>/executionroot/8db36740-9455-4ff1-aee3-b9c51994fd5f/app/node_modules/.bin/cds-serve: cannot execute: Permission denied
Thanks in advance
Best Regards
Srujan
Request clarification before answering.
Hi @rgadirov and @srujan_gannamaneni ,
Where you able to resolve the issue?
I have the same problem: "Error: Cannot find module '../lib'"
Thank you
Kevin
EDIT: sorry, missed the reply with the solution
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello,
I have found a solution to this deployment issue:
And my mta.yaml snippet for service module looks like this:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The error message indicates that the `cds-serve` command cannot be executed due to permission issues.
Ensure that the `cds-serve` file has the correct permissions. You can use the `chmod` command to change the permissions. Also, the user must have to running the deployment process the necessary permissions to execute the `cds-serve` command. You may need to run the deployment process as a different user or modify the permissions of the current user.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Hakan
You are correct. I later tried to deploy the code using different user and this error didnt reproduce but I am still facing issue. Now it doesnt seem like access issue but it is unable to find the bin folder or cds-serve. Can you please review this error log screenshot and suggest how this issue can be alleviated?
Thanks and Regards
Srujan Gannamaneni
Hi @HakanHaslaman,
I am experiencing the same issue. This seems to happen with CDS related applications, because it is unknown to classic node js developers. I am trying to deploy a SAP CAP based application to HANA XSA from VS Code, and getting the exact same "Access Denied" issue. I already authorized and used chmod x to cds-serve and the error still occurs (See here: -rwxr-xr-x 1 NT-SBB1+e573091 4096 391 Aug 6 11:55 cds-serve*)
You also mentioned that the user must be authorized to deploy. My colleague is already able to deploy soutions (especially nodejs), but even with his user it doesn´t seem to be possible to deploy, Can you possible advise what else one could consider? Or is a SAP ticket required to solve this issue? The client uses HANA XSA as platform and the idea is to use the latest SAP CAP Framework to develop the appliction.
@thomas_jung Maybe you also have some idea. I also tried out your tutorial for SAP CAP development on HANA XSA (which is from 2021 btw. and based on WebIDE).
I can kindly provide more technical details on version etc. (nodeJS v22, CDS 9).
Update: In package.json of cap root project, I added now:
Thank you for your support in advance.
Best regards
Rufat
| User | Count |
|---|---|
| 11 | |
| 6 | |
| 5 | |
| 4 | |
| 3 | |
| 3 | |
| 2 | |
| 2 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.