cancel
Showing results for 
Search instead for 
Did you mean: 

CAP: /app is not built

former_member460045
Participant
0 Kudos

Dear community

I have created a CAP with integrated UI in /app folder.

Those are working fine, locally.

For the build I use:

cds build --production

It creates gen/db and gen/srv. But I'm missing the gen/app.

Any idea, why this might be?

Best regards

Johannes

lothar_bender
Advisor
Advisor
0 Kudos

Hi joso,
actually, this is the correct default behaviour. You may want to check the console log. I assume that you'll find an entry that two build tasks were executed - a 'hana' build task and a 'nodejs' build task.
The first build task is creating the HANA deployment artefacts in the folder 'gen/db' while the second is creating the artefacts required by the Nodejs runtime in the folder 'gen/srv'.

Thus, no CDS related artefacts are created in the folder 'gen/app' - the 'app/' folder should only contain UI related content. Are some CDS artefacts missing?

Regards,
Lothar

former_member460045
Participant
0 Kudos

Hi Lothar, thanks for your quick answer.

I will elaborate a bit more:

I was trying to implement this blog post: https://blogs.sap.com/2020/07/08/ui5-freestyle-app-in-cap/
In this post, the author shows a picture, of his /gen folder, that is containing the ui ressources as well.

When my /app folder wasnt created, I tried to include it manually into my mta.yaml, to deploy it with the cds artifacts, but I get the error: no start command defined.

Best regards

Johannes

View Entire Topic
gregorw
Active Contributor

Hi Johannes,

just today I've added the deployment to SAP BTP Cloud foundry to the project sap-support-message-reporting. Check out the commit and I hope that you get that you need to use the approuter or another option would be to copy the app content to the gen/srv folder if you don't have authentication enabled.

Best regards
Gregor

former_member460045
Participant

Hello Gregor,

thanks! I'll try that out and reach back out, if it won't work.

I really appreciate your work and commitment to the community a lot!

Best regards

Johannes