2016-04-08 12 views
1

私はIBM Bluemixクラウド上でpythonアプリケーションをclodfoundry経由でデプロイしようとしています。ビルドパックのコンパイルは失敗します。ログCloudfoundry:pythonで一致するディストリビューションが見つかりませんでした== 3.5.0

2016-04-08T09:23:04.732-0400[API/1]OUTUpdated app with guid 4823889e-5491-40a3-a8ce-35b8dd325441 ({"state"=>"STOPPED"}) 2016-04-08T09:23:07.713-0400[DEA/4]OUTGot staging request for app with id 4823889e-5491-40a3-a8ce-35b8dd325441 2016-04-08T09:23:11.178-0400[API/0]OUTUpdated app with guid 4823889e-5491-40a3-a8ce-35b8dd325441 ({"state"=>"STARTED"}) 2016-04-08T09:23:11.376-0400[STG/4]OUT-----> Downloaded app package (72K) 2016-04-08T09:23:12.762-0400[STG/4]OUT-----> Downloaded app buildpack cache (29M) 2016-04-08T09:23:12.901-0400[STG/0]ERRCloning into '/tmp/buildpacks/buildpack-python'... 2016-04-08T09:23:14.625-0400[STG/0]OUTSubmodule 'compile-extensions' (https://github.com/cloudfoundry/compile-extensions.git) registered for path 'compile-extensions' 2016-04-08T09:23:14.679-0400[STG/0]ERRCloning into 'compile-extensions'... 2016-04-08T09:23:15.534-0400[STG/0]OUTSubmodule path 'compile-extensions': checked out '9932bb1d352b88883d76df41e797a6fa556844f0' 2016-04-08T09:23:15.782-0400[STG/0]OUT-------> Buildpack version 1.5.5 2016-04-08T09:23:16.785-0400[STG/0]OUT-----> Found python-2.7.10, removing 2016-04-08T09:23:17.035-0400[STG/0]OUT-----> Installing python-3.5.0 2016-04-08T09:23:21.330-0400[STG/0]OUTDownloaded [https://pivotal-buildpacks.s3.amazonaws.com/concourse-binaries/python/python-3.5.0-linux-x64.tgz] 2016-04-08T09:23:27.161-0400[STG/0]OUT ! Please remove to ensure expected behavior. 2016-04-08T09:23:27.161-0400[STG/0]OUT ! The package setuptools/distribute is listed in requirements.txt. 2016-04-08T09:23:29.058-0400[STG/0]OUT $ pip install -r requirements.txt 2016-04-08T09:23:29.728-0400[STG/0]ERRDEPRECATION: --allow-all-external has been deprecated and will be removed in the future. Due to changes in the repository protocol, it no longer has any effect. 2016-04-08T09:23:29.757-0400[STG/0]OUT Collecting django==1.9.5 (from -r mysite/requirements.txt (line 1)) 2016-04-08T09:23:30.078-0400[STG/0]OUT Downloading Django-1.9.5-py2.py3-none-any.whl (6.6MB) 2016-04-08T09:23:32.696-0400[STG/0]OUT Collecting docopt==0.6.2 (from -r mysite/requirements.txt (line 2)) 2016-04-08T09:23:32.758-0400[STG/0]OUT Downloading docopt-0.6.2.tar.gz 2016-04-08T09:23:33.446-0400[STG/0]OUT Collecting elasticsearch==2.3.0 (from -r mysite/requirements.txt (line 3)) 2016-04-08T09:23:33.525-0400[STG/0]OUT Downloading elasticsearch-2.3.0-py2.py3-none-any.whl (51kB) 2016-04-08T09:23:33.552-0400[STG/0]OUT Collecting hdfs==2.0.5 (from -r mysite/requirements.txt (line 4)) 2016-04-08T09:23:33.631-0400[STG/0]OUT Downloading hdfs-2.0.5.tar.gz 2016-04-08T09:23:34.330-0400[STG/0]OUT Collecting python==3.5.0 (from -r mysite/requirements.txt (line 6)) 2016-04-08T09:23:34.364-0400[STG/0]ERR Could not find a version that satisfies the requirement python==3.5.0 (from -r mysite/requirements.txt (line 6)) (from versions:) 2016-04-08T09:23:34.962-0400[STG/0]ERRNo matching distribution found for python==3.5.0 (from -r mysite/requirements.txt (line 6)) 2016-04-08T09:23:35.249-0400[STG/0]OUTStaging failed: Buildpack compilation step failed 2016-04-08T09:23:35.468-0400[API/0]ERRencountered error: App staging failed in the buildpack compile phase

私の要件

ジャンゴ== 1.9.5 docopt == 0.6.2 elasticsearchの== 2.3.0
HDFS == 2.0.5
ピップ== 8.1 0.1
のpython == 3.5.0
要求== 2.9.1
setuptoolsの== 20.3
のsimplejsonの== 3.8.2
6 == 1.10.0
urllib3 == 1.14
vs2015_runtime == 14.00.23026.0
ホイール== 0.29.0

私は

cf push pytest -b https://github.com/cloudfoundry/buildpack-python.git

どのように私すべきを実行したコマンドこれを展開しますか?

編集

私は2.7.10にPythonのバージョンを変更してvs2015-runtime==14.00.23026.0要件を削除しました。今私は

$ python mysite/manage.py collectstatic --noinput 
     Traceback (most recent call last): 
     File "mysite/manage.py", line 10, in <module> 
      execute_from_command_line(sys.argv) 
     File "/app/.heroku/python/lib/python2.7/site-packages/django/core/manag 
ement/__init__.py", line 354, in execute_from_command_line 
      utility.execute() 
     File "/app/.heroku/python/lib/python2.7/site-packages/django/core/manag 
ement/__init__.py", line 346, in execute 
      self.fetch_command(subcommand).run_from_argv(self.argv) 
     File "/app/.heroku/python/lib/python2.7/site-packages/django/core/manag 
ement/__init__.py", line 190, in fetch_command 
      klass = load_command_class(app_name, subcommand) 
     File "/app/.heroku/python/lib/python2.7/site-packages/django/core/manag 
ement/__init__.py", line 41, in load_command_class 
      return module.Command() 
     File "/app/.heroku/python/lib/python2.7/site-packages/django/contrib/st 
aticfiles/management/commands/collectstatic.py", line 32, in __init__ 
      self.storage.path('') 
     File "/app/.heroku/python/lib/python2.7/site-packages/django/contrib/st 
aticfiles/storage.py", line 48, in path 
      raise ImproperlyConfigured("You're using the staticfiles app " 
     django.core.exceptions.ImproperlyConfigured: You're using the staticfiles 
app without having set the STATIC_ROOT setting to a filesystem path. 
!  Error while running '$ python mysite/manage.py collectstatic --noinput'. 
     See traceback above for details. 
     You may need to update application code to resolve this error. 
     Or, you can disable collectstatic for this application: 
      $ heroku config:set DISABLE_COLLECTSTATIC=1 
     https://devcenter.heroku.com/articles/django-assets 
Staging failed: Buildpack compilation step failed 

、ここでは私のプロジェクトのセットアップは

enter image description here

と私のsettings.pyに私が間違って何を

STATIC_ROOT = os.path.join(BASE_DIR, '/static') 
STATIC_URL = '/static/' 

やっているように見えるものになってしまいますか?

更新

おかげであなたの助けのためにたくさんホバートブッシュ。私はあなたが示唆したように、今私はほとんどそこにいます。問題は、現在、私の静的ファイルのいくつかをdjangoが見つけることができないということです。私は

hdfsProps = ReadProp.load_properties("hdfsStats/props/hdfsprops.prop") 

ようなコードの部分を持っており、ここでのレイアウトは、私はこれら二つの小道具ファイルを読みたい

enter image description here

です。これは私のローカルPCで完全に動作することに注意してください。 「静的」の内部にhdfsStas/props/構造体を作成しない場合でも

私のレイアウトを変更して、これらのファイルを拾うことができますか?私も../../props/hdfsprops.propを試しましたが、それは私に同じエラーを与えます。最後に、ファイルを読み取るコードはsrcパッケージ内にあります

答えて

1

これはBluemix Python Buildpackを使用して現在サポートされている最高ランタイムレベルであるため、Pythonランタイム2.7.10に戻してください。

+0

ありがとう、私はそれを2.7.10に変更しましたが、vs2015-runtime == 14.00.23026.0の一致するディストリビューションが見つかりませんでした。 – AbtPst

+0

@AbtPst cf logs -recentの出力を提供できますか? –

+0

編集を参照してください – AbtPst

関連する問題