我们使用 gitreceive[0] 将 deploy 与 git push 一起使用 Git receive 使用 pre-receive 钩子来执行诗歌。我们的依赖项之一是从 github 中提取的。
诗歌在安装过程中崩溃。这只发生在使用 pre-recieve 钩子调用时。以用户本身的身份调用它不会导致崩溃。
Pipenv 对此没有任何问题。
我能做些什么来解决这个问题?
$ git push test test
Enumerating objects: 22, done.
Counting objects: 100% (22/22), done.
Delta compression using up to 8 threads
Compressing objects: 100% (19/19), done.
Writing objects: 100% (19/19), 19.33 KiB | 9.67 MiB/s, done.
Total 19 (delta 12), reused 0 (delta 0)
----> Deploying app...
Virtualenv app-py3.6 already exists.
Using virtualenv: /home/git/.cache/pypoetry/virtualenvs/app-py3.6
Installing dependencies from lock file
remote:
remote: [CalledProcessError]
remote: Command '['git', 'clone', 'https://github.com/rvanlaar/django-tls', '/tmp/py
remote: poetry-git-django-tlsif0u0cp9']' returned non-zero exit status 128.
remote:
remote: Exception trace:
remote: /home/git/.local/lib/python3.6/site-packages/cleo/application.py in run() at line 94
remote: status_code = self.do_run(input_, output_)
remote: /home/git/.local/lib/python3.6/site-packages/poetry/console/application.py in do_run() at line 88
remote: return super(Application, self).do_run(i, o)
remote: /home/git/.local/lib/python3.6/site-packages/cleo/application.py in do_run() at line 197
remote: status_code = command.run(input_, output_)
remote: /home/git/.local/lib/python3.6/site-packages/poetry/console/commands/command.py in run() at line 77
remote: return super(BaseCommand, self).run(i, o)
remote: /home/git/.local/lib/python3.6/site-packages/cleo/commands/base_command.py in run() at line 146
remote: status_code = self.execute(input_, output_)
remote: /home/git/.local/lib/python3.6/site-packages/cleo/commands/command.py in execute() at line 107
remote: return self.handle()
remote: /home/git/.local/lib/python3.6/site-packages/poetry/console/commands/install.py in handle() at line 55
remote: return_code = installer.run()
remote: /home/git/.local/lib/python3.6/site-packages/poetry/installation/installer.py in run() at line 73
remote: self._do_install(local_repo)
remote: /home/git/.local/lib/python3.6/site-packages/poetry/installation/installer.py in _do_install() at line 229
remote: ops = solver.solve(use_latest=whitelist)
remote: /home/git/.local/lib/python3.6/site-packages/poetry/puzzle/solver.py in solve() at line 38
remote: packages, depths = self._solve(use_latest=use_latest)
remote: /home/git/.local/lib/python3.6/site-packages/poetry/puzzle/solver.py in _solve() at line 171
remote: self._package, self._provider, locked=locked, use_latest=use_latest
remote: /home/git/.local/lib/python3.6/site-packages/poetry/mixology/__init__.py in resolve_version() at line 7
remote: return solver.solve()
remote: /home/git/.local/lib/python3.6/site-packages/poetry/mixology/version_solver.py in solve() at line 79
remote: next = self._choose_package_version()
remote: /home/git/.local/lib/python3.6/site-packages/poetry/mixology/version_solver.py in _choose_package_version() at line 354
remote: packages = self._provider.search_for(dependency)
remote: /home/git/.local/lib/python3.6/site-packages/poetry/puzzle/provider.py in search_for() at line 133
remote: packages = self.search_for_vcs(dependency)
remote: /home/git/.local/lib/python3.6/site-packages/poetry/puzzle/provider.py in search_for_vcs() at line 174
remote: git.clone(dependency.source, tmp_dir)
remote: /home/git/.local/lib/python3.6/site-packages/poetry/vcs/git.py in clone() at line 45
remote: return self.run("clone", repository, str(dest))
remote: /home/git/.local/lib/python3.6/site-packages/poetry/vcs/git.py in run() at line 101
remote: subprocess.check_output(["git"] + list(args), stderr=subprocess.STDOUT)
remote: /usr/lib/python3.6/subprocess.py in check_output() at line 356
remote: **kwargs).stdout
remote: /usr/lib/python3.6/subprocess.py in run() at line 438
remote: output=stdout, stderr=stderr)
remote:
remote: install [--no-dev] [--dry-run] [-E|--extras EXTRAS] [--develop DEVELOP]
remote:
To test.example.com:app
! [remote rejected] test -> test (pre-receive hook declined)