cancel
Showing results for 
Search instead for 
Did you mean: 

CF multitenancy: Cloud not expose multitenant app as a Saas in SAP CF

Ranjith
Participant

Hi all,

I trying to implement a shell plugin for SAP CF launchpad by referring the https://help.sap.com/viewer/ad4b9f0b14b0458cad9bd27bf435637d/Cloud/en-US/8a25fddb747f4ba992969049de9... and i can successfully implement it in my runtime fiori launchpad.

Now i need to implement this shell plugin to my Site-manager FIORI Launchpad. To achieve this i'm trying to expose my multi-tenant app as content provider by referring https://help.sap.com/viewer/ad4b9f0b14b0458cad9bd27bf435637d/Cloud/en-US/8a25fddb747f4ba992969049de9....

I have configured the mta.yaml and can see the multi-tenant application as SaaS Provisioning service in my subaccount subscription section.

But when i try to subscribe my multi-tenent Saas service it throwing a error saying Could not enable application: Internal Server Error (500). Can anyone help me this scenario or is there any way to add the shell plugin to the sitemanager FLP.

mtayaml.txt

ID: cap
_schema-version: '2.1'
parameters:
  deploy_mode: html5-repo
version: 0.0.1
modules:
  - name: cap-approuter
    type: approuter.nodejs
    path: cap-approuter
    parameters:
      keep-existing-routes: true
      buildpack: nodejs_buildpack
      disk-quota: 256M
      memory: 256M
      routes:
        - route: 344e01a4trial-dev-cap-approuter.cfapps.eu10.hana.ondemand.com
    properties:
      TENANT_HOST_PATTERN: ^(.*)-dev-cap-approuter.cfapps.eu10.hana.ondemand.com
      SAP_JWT_TRUST_ACL: "[{\"clientid\":\"*\",\"identityzone\":\"sap-provisioning\"}]"
    requires:
      - name: cap_html5_repo_runtime
      - name: portal_resources_cap
      - name: cap-uaa
      - name: saas-cap-registry-application
      - name: srv_api
        group: destinations
        properties:
          forwardAuthToken: true
          strictSSL: false
          name: srv_api
          url: '~{url}'
  - name: cap_ui_deployer
    type: com.sap.html5.application-content
    path: cap_ui_deployer
    requires:
      - name: cap_html5_repo_host
    build-parameters:
      requires:
        - name: HTML
          artifacts:
            - './*'
          target-path: resources/HTML
        - name: CustomerWeb
          artifacts:
            - './*'
          target-path: resources/CustomerWeb
        - name: bookmarkplugin
          artifacts:
            - './*'
          target-path: resources/bookmarkplugin
  - name: cap-db
    type: hdb
    path: db
    parameters:
      memory: 256M
      disk-quota: 512M
    requires:
      - name: cap-db-hdi-container
  - name: cap-srv
    type: nodejs
    path: srv
    parameters:
      memory: 512M
      disk-quota: 512M
    provides:
      - name: srv_api
        properties:
          url: '${default-url}'
    requires:
      - name: cap-db-hdi-container
      - name: cap-uaa
  - name: HTML
    type: html5
    path: HTML
    build-parameters:
      builder: custom
      commands:
        - npm install
        - npm run build
      supported-platforms: []
      build-result: dist
  - name: FLP
    type: com.sap.portal.content
    path: FLP
    parameters:
      stack: cflinuxfs3
      memory: 128M
      buildpack: 'https://github.com/cloudfoundry/nodejs-buildpack/releases/download/v1.6.39/nodejs-buildpack-cflinuxfs3-v1.6.39.zip'
    properties:
      TENANT_HOST_PATTERN: ^(.*)-dev-cap-approuter.cfapps.eu10.hana.ondemand.com
    requires:
      - name: portal_resources_cap
      - name: cap-uaa
      - name: cap_html5_repo_host
      - name: cap_ui_deployer
      - name: saas-cap-registry-application
  - name: CustomerWeb
    type: html5
    path: CustomerWeb
    build-parameters:
      builder: custom
      commands:
        - npm install
        - npm run build
      supported-platforms: []
      build-result: dist
  - name: bookmarkplugin
    type: html5
    path: bookmarkplugin
    build-parameters:
      builder: custom
      commands:
        - npm install
        - npm run build
      supported-platforms: []
      build-result: dist
resources:
  - name: saas-cap-registry-application
    type: org.cloudfoundry.managed-service
    parameters:
      service: saas-registry
      service-plan: application
      config:
        xsappname: cap-dev!t36451
        appUrls:
          onSubscription: https://344e01a4trial-dev-cap-approuter.cfapps.eu10.hana.ondemand.com/callback/v1.0/tenants/{tenantI...
          getDependencies: https://344e01a4trial-dev-cap-approuter.cfapps.eu10.hana.ondemand.com/callback/v1.0/dependencies
        category: FIORI APPS hana CLI
        description: FIORI App test hana CLI
        displayName: CAP MTA hana Cli app
  - name: cap_html5_repo_runtime
    parameters:
      service-plan: app-runtime
      service: html5-apps-repo
    type: org.cloudfoundry.managed-service
  - name: cap_html5_repo_host
    parameters:
      service-plan: app-host
      service: html5-apps-repo
    type: org.cloudfoundry.managed-service
  - name: cap-db-hdi-container
    type: com.sap.xs.hdi-container
    properties:
      hdi-container-name: '${service-name}'
    parameters:
      service: hanatrial
      service-plan: hdi-shared
  - name: cap-uaa
    type: org.cloudfoundry.managed-service
    parameters:
      service-plan: application
      service: xsuaa
      path: ./xs-security.json
      config:
        xsappname: 'cap-${space}'
        tenant-mode: dedicated
  - name: dest_cap
    parameters:
      service-plan: lite
      service: destination
    type: org.cloudfoundry.managed-service
  - name: portal_resources_cap
    parameters:
      service-plan: standard
      service: portal
    type: org.cloudfoundry.managed-service
christoffer_fuss
Participant
0 Kudos

I followed the same links but without using cap. I created a MTA project in WebIDE instead and this was working fine, so I could add this application to my portal service launchpad.
I will try tomorrow to do the same with my cap project and let you know, if this is working as well.

Best Regards,

Chris

Ranjith
Participant
0 Kudos

sub.pngHi christoffer.fuss

Now i can subscribe the created SaaS service. But it is not visible in my contentprovider section of my portal service. Do we need to share anything more to make it visible in the portal service. if possible could you please share your code via mail or github.

cm.png

Thanks & regards,

Ranjithkumar

christoffer_fuss
Participant
0 Kudos

In which subaccount are you running your portal service? In the subaccount, where your app is hosted, it is not visible for me as well. In the subaccount, where the app is subscribed, it is visible. I have done no further steps after the successful subscription.

christoffer_fuss
Participant
0 Kudos

No I don't know if it is possible to get it working in the same subaccount, I am also interessted to achieve this, so please let me know if you get this working 😉

Best regardsm

Chris

Ranjith
Participant
0 Kudos

Hi Christoffer,

I think SAP has updated some content in portal service. Now the HTML Repo content provider is automatically appearing in the Content Provider Section of the portal and follow the https://help.sap.com/viewer/956efb6db08c450bb303a0d316b72f10/Cloud/en-US/3a0e6d6b791c4c2189f6a0a4241... to add a HTML5 app or plugin app as a content provider in the same sub-account.

I'm trying to achieve this, but i couldn't .Please let me know once you can achieve this.

Thanks & Regards,

Ranjithkumar Ayyavu

antonette_oberholster
Active Contributor
0 Kudos

Hi

Have you been able to achieve this? I was able to subscribe to the subscription, but not seeing the plugin in the Content Provider section of Portal Service.

Regards

Antonette

Ranjith
Participant
0 Kudos

Hi Antonette Venter,

Yes. I did. But if you are going to follow this method then you need to create a two subaccout as Christoffer Fuss mentioned in the above comment.

Note : As per SAP it is possible to achieve this in same subaccount. Please refer https://answers.sap.com/questions/13121628/couldnt-expose-the-html-content-in-portal.html. If you can do this in same subaccount please let me know. Because i'm trying it for last one month but i couldn't.

antonette_oberholster
Active Contributor
0 Kudos

Hi ranjith13119-gmail.com

Thanks, I'll let you know if I find a way. How were you able to expose your app to the second subaccount's HTML5 repository?

Regards

Antonette

christoffer_fuss
Participant
0 Kudos

Hi antonette.venter ,

are you still struggeling with this? You can also try this approach where you dont need a second subaccount. For me both approaches are working.

Best Regards,

Chris

Ranjith
Participant
0 Kudos

HI christoffer.fuss ,

Is it possible to add the plugin app by using the link which you sepcified in the above command?

I tired it for all the apps(HTML5, BSP, Deeplinks). It is working fine.

But i could achive it for plugin app. If though what is the Semantic object and Action for the plugin app?

Is it #Shell-plugin ?

Do we need to add this app to Group or catalog. What is the visualization Tile type(Static, Dynamic or None) for Plugin app?

Could you please confirm.

Accepted Solutions (1)

Accepted Solutions (1)

Ranjith
Participant
0 Kudos

Hi Christoffer,

As you said it is visible in my portal service of another subaccount where the app is subscribed. Is there any possibility to achieve in the same subaccount(in the subaccount, where the app is hosted).

If we are going to follow this approach to add a plugin app in the portal FLP, then we need to create a two subaccount for all the global accounts.


Thanks & Regards,

Ranjithkumar

Answers (0)