我是scrapyd的新手, 我已將以下代碼插入到scrapy.cfg文件中。項目未在scrapyd中顯示
[settings]
default = uk.settings
[deploy:scrapyd]
url = http://localhost:6800/
project=ukmall
[deploy:scrapyd2]
url = http://scrapyd.mydomain.com/api/scrapyd/
username = john
password = secret
如果我運行下面的代碼代碼
$scrapyd-deploy -l
我能得到
scrapyd2 http://scrapyd.mydomain.com/api/scrapyd/
scrapyd http://localst:6800/
要查看所有可用的項目
scrapyd-deploy -L scrapyd
但它說明不了什麼在我的機器?
編號:http://scrapyd.readthedocs.org/en/latest/deploy.html#deploying-a-project
如果難道
$ scrapy deploy scrapyd2
[email protected]:~/ScrapyProject/mall_uk$ scrapy deploy scrapyd2
Packing version 1412322816
Traceback (most recent call last):
File "/usr/bin/scrapy", line 4, in <module>
execute()
File "/usr/lib/pymodules/python2.7/scrapy/cmdline.py", line 142, in execute
_run_print_help(parser, _run_command, cmd, args, opts)
File "/usr/lib/pymodules/python2.7/scrapy/cmdline.py", line 88, in _run_print_help
func(*a, **kw)
File "/usr/lib/pymodules/python2.7/scrapy/cmdline.py", line 149, in _run_command
cmd.run(args, opts)
File "/usr/lib/pymodules/python2.7/scrapy/commands/deploy.py", line 103, in run
egg, tmpdir = _build_egg()
File "/usr/lib/pymodules/python2.7/scrapy/commands/deploy.py", line 228, in _build_egg
retry_on_eintr(check_call, [sys.executable, 'setup.py', 'clean', '-a', 'bdist_egg', '-d', d], stdout=o, stderr=e)
File "/usr/lib/pymodules/python2.7/scrapy/utils/python.py", line 276, in retry_on_eintr
return function(*args, **kw)
File "/usr/lib/python2.7/subprocess.py", line 540, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['/usr/bin/python', 'setup.py', 'clean', '-a', 'bdist_egg', '-d', '/tmp/scrapydeploy-VLM6W7']' returned non-zero exit status 1
[email protected]:~/ScrapyProject/mall_uk$
如果我這樣做的另一個項目是指它顯示。
$ scrapy deploy scrapyd
Packing version 1412325181
Deploying to project "project2" in http://localhost:6800/addversion.json
Server response (200):
{"status": "error", "message": "[Errno 13] Permission denied: 'eggs'"}
你有沒有真的部署任何東西到你的本地scrapyd呢? – dataisbeautiful 2014-10-03 07:38:55
我不知道,請告訴我如何部署 – 2014-10-03 07:44:55
我只是在引用文檔並執行相同的操作(http://scrapyd.readthedocs.org/en/latest/deploy.html#deploying-a-project)。但我有一個scrapy項目。 – 2014-10-03 07:46:19