3
votes

We want to deploy an existing application in IBM Bluemix. Using Python command prompt we have pushed the application in IBM Bluemix, but when we deploy it in IBM, it won't work. It is giving the following errors:

Creating container Successfully created container Downloading app package... Downloaded app package (1.5K) Staging... Downloaded build artifacts cache (31.3M) None of the buildpacks detected a compatible application Exit status 222 Staging failed: Exited with status 222 Destroying container

FAILED Error restarting application: NoAppDetectedError TIP: Buildpacks are detected when the "cf push" is executed from within the directory that contains the app source code.

Use 'cf buildpacks' to see a list of supported buildpacks.

Use 'cf logs glucose_tracker_monitor --recent' for more in depth log information.

Finished: FAILED

I don't know what to do after this. Can anyone help me with these errors?

1
Have you mentioned buildpack in the manifest.yml file? Are you using this buildpack? github.com/heroku/heroku-buildpack-pythonRiyaMRoy
Can you please add you code and directory structure of your application? You should have at least the python file in the directory structure so the buildpack can detect it and push your application to Bluemix.Alex da Silva

1 Answers

2
votes

The message "None of the buildpacks detected a compatible application" means that none of the buildpacks installed in Bluemix have recognized your project as a project that they can run.

From the Bluemix documentation for the Python buildpack, your application needs to include either a "setup.py" or "requirements.txt" file to make this buildpack "detect" your application as something that it can run.

The "requirements.txt" file is used to specify any pip packages that your application needs to be installed. For an example, see the requirements.txt file in the "get-started-python" project in the "IBM-Bluemix" GitHub repository.

Your application should also include a file named "Procfile" which will specify how the buildpack should start your application.

Example "Procfile":

web: python hello.py

This would cause the buildpack to run the command python hello.py when starting the application.