cancel
Showing results for 
Search instead for 
Did you mean: 

How to deploy UI5 app with Standalone approuter to CloudFoundry

rchudziak
Participant
0 Kudos

I would like to create a SAPUI5 app with Standalone approuter and deploy it to CloudFoundry. All tutorials are about creating apps with the Managed approuter and deployed to the Launchpad service so I am kind of lost here.

I have followed steps for Standalone router app described here: https://github.com/SAP-samples/multi-cloud-html5-apps-samples/tree/master/standalone-approuter-html5... and all worked fine. This is a really basic scenario.

So I have created a SAPUI5 app, following all the steps here: https://github.com/SAP-samples/cloud-extension-html5-sample/blob/mission/mission/create-application/...

With the exception of not having managed application router in step 7.

Now when trying to deploy using 'cf push', the app appears in CloudFoundry -> Spaces -> Applications. But it is stuck in a 'Starting Service' loop. So I deleted it.

Then tried to build it and then 'cf deploy' it. It doesn't appear there under 'Applications'. If I run 'cf html5-list' it appears on the list but the visibility is listed as private.

Where am I going wrong?

AshGoyal
Participant
0 Kudos

@radek_c - The steps for creating application for standalone router would be little bit different then what are given in the github library above. I have written a blog (see link below)) for the steps specific to standalone router.

https://blogs.sap.com/2022/04/08/building-and-deploying-a-standalone-fiori-apps-in-sap-btp-cloud-fou...

Accepted Solutions (0)

Answers (2)

Answers (2)

rchudziak
Participant

I think the issue is with the recently changed Template Generators. I now tried the SAP Fiori Freestyle project (Deprecated) and it has created the correct project structure as described here: https://help.sap.com/viewer/584e0bcbfd4a4aff91c815cefa0bce2d/Cloud/en-US/8fac387cbcb541f7a78dcb18610...

So I had a separate folder (HTML5Module) for my ui5 app and a separate folder (router) for the approuter. Just like here: https://github.com/SAP-samples/multi-cloud-html5-apps-samples/tree/master/standalone-approuter-html5...

And the deployment worked.

If I use the non-deprecated SAP Fiori Freestyle project generator, it doesn't do the split and the app structure looks like an app with a managed approuter. Now, I am not sure if this is a bug or a feature?

RobinReeb
Advisor
Advisor
0 Kudos

I wrote a blog post on that topic on how to structure the mta files to provide a standalone and a managed approuter deployment for any UI5 application.

https://blogs.sap.com/2022/11/01/build-and-deploy-ui5-freestyle-applications-to-sap-btp-cloud-foundr...

Might be a bit late for your particular case, but hoping this might help others stumbling across this post here via Google.

mts2605_orsted
Explorer
0 Kudos

Hi Robin
How come the link to your blog post does not work anymore?

KR Michael

RobinReeb
Advisor
Advisor
0 Kudos

Hi Michael,

It had to be taken down temporarily for an additional edit, but now it is back up!
Sorry for the inconveniences and hope it will be beneficial to you!

Very best regards,
Robin