1
votes

The command I used was: ibmcloud target --cf

The error I receive is given below:

-----> Finalizing Dotnet Core ERROR Unable to install dotnet-runtime: could not find a version o f dotnet-runtime to install Failed to compile droplet: Failed to run finalize script: exit status 12 Exit status 223 Cell 0f7012eb-9e32-4fdf-ba92-85aee4639139 stopping instance e5256fa6-702e-41f 2-8c49-039400712a85 Cell 0f7012eb-9e32-4fdf-ba92-85aee4639139 destroying container for instance e 5256fa6-702e-41f2-8c49-039400712a85 Error staging application: App staging failed in the buildpack compile phase FAILED

2
I am new to cloud foundry and don't know how to solve this. Can anyone please help? - Shilps
Welcome to SO, kindly visit this to understand how we expect questions. - Elysian Storm
Can you more information like manifest.yml, details about your .NET project? - Vidyasagar Machupalli
yes,my manifest.yml has the following: applications: - name: <App-Name> random-route: true memory: 128M I tried pushing via below command today, cf push APP-NAME -b github.com/cloudfoundry/dotnet-core-buildpack.git It is still giving error: -----> Finalizing Dotnet Core ERROR Unable to install dotnet-runtime: could not find a version o f dotnet-runtime to install Failed to compile droplet: Failed to run finalize script: exit status 12 Exit status 223 Error staging application: App staging failed in the buildpack compile phase FAILED - Shilps

2 Answers

0
votes

This is what I tried and worked for me

  • Installed IBM Cloud CLI
  • Followed the instructions in the documentation here to clone a getting started dotnet application
  • Cloned the sample app and cd into the folder
  • Run
ibmcloud cf push

You should see a random URL generated with the todo app

Use a Cloud Foundry CLI that's managed by IBM to work with Cloud Foundry resources through the IBM Cloud CLI. If you have a separate Cloud Foundry CLI (cf) installation, don't use both ibmcloud cf commands and cf commands in the same context. Instead, use only ibmcloud cf [command] to manage resources in the IBM Cloud CLI context. More info here

0
votes

after a lot of work and help from people I found out that I was using the wrong buildpack. If your application is built in ASP.Net framework 4.5 or newer then you need to use the hwc pack. Also, your manifest.yml will need changes. This is my manifest.yml.

applications:

  • name: random-route: true memory: 128M buildpack: https://github.com/cloudfoundry/hwc-buildpack.git env: DOTNET_CLI_TELEMETRY_OPTOUT: 1 DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true

This works. Create a toolchain build and deploy.