Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

debops-update : no such file or directory #123

Closed
leviwheatcroft opened this issue Aug 6, 2015 · 8 comments
Closed

debops-update : no such file or directory #123

leviwheatcroft opened this issue Aug 6, 2015 · 8 comments

Comments

@leviwheatcroft
Copy link

I've been following through the the installation instructions here.

When I get to debops-update I get the output below. I'm a bit naive to this, I tried creating the directory mentioned in the second line, but I get the same error, looks like something to do with the install_path


levi@debianOffice:~$ debops-update
DebOps playbooks have not been found, installing into /home/levi/.local/share/debops/debops-playbooks

Traceback (most recent call last):
File "/usr/local/bin/debops-update", line 220, in
main(args.project_dir)
File "/usr/local/bin/debops-update", line 201, in main
clone_git_repository(PLAYBOOKS_GIT_URI, 'master', install_path)
File "/usr/local/bin/debops-update", line 129, in clone_git_repository
repo_uri, destination])
File "/usr/lib/python2.7/subprocess.py", line 522, in call
return Popen(_popenargs, *_kwargs).wait()
File "/usr/lib/python2.7/subprocess.py", line 710, in init
errread, errwrite)
File "/usr/lib/python2.7/subprocess.py", line 1335, in _execute_child
raise child_exception

OSError: [Errno 2] No such file or directory

@drybjed
Copy link
Member

drybjed commented Aug 6, 2015

So you tried DebOps from pypi? Can you try with version from GitHub and see if you get the same result?

@leviwheatcroft
Copy link
Author

different issue...

root@hmoffice:/etc/ansible/playbooks# pip install https://github.com/debops/debops/archive/master.zip
Downloading/unpacking https://github.com/debops/debops/archive/master.zip
  Downloading master.zip (unknown size): 69kB downloaded
Cleaning up...
Exception:
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/pip/basecommand.py", line 122, in main
    status = self.run(options, args)
  File "/usr/lib/python2.7/dist-packages/pip/commands/install.py", line 290, in run
    requirement_set.prepare_files(finder, force_root_egg_info=self.bundle, bundle=self.bundle)
  File "/usr/lib/python2.7/dist-packages/pip/req.py", line 1198, in prepare_files
    do_download,
  File "/usr/lib/python2.7/dist-packages/pip/req.py", line 1376, in unpack_url
    self.session,
  File "/usr/lib/python2.7/dist-packages/pip/download.py", line 572, in unpack_http_url
    download_hash = _download_url(resp, link, temp_location)
  File "/usr/lib/python2.7/dist-packages/pip/download.py", line 433, in _download_url
    for chunk in resp_read(4096):
  File "/usr/lib/python2.7/dist-packages/pip/download.py", line 421, in resp_read
    chunk_size, decode_content=False):
  File "/usr/lib/python2.7/dist-packages/urllib3/response.py", line 256, in stream
    data = self.read(amt=amt, decode_content=decode_content)
  File "/usr/lib/python2.7/dist-packages/urllib3/response.py", line 186, in read
    data = self._fp.read(amt)
  File "/usr/lib/python2.7/httplib.py", line 573, in read
    s = self.fp.read(amt)
  File "/usr/lib/python2.7/socket.py", line 380, in read
    data = self._sock.recv(left)
  File "/usr/lib/python2.7/dist-packages/urllib3/contrib/pyopenssl.py", line 188, in recv
    data = self.connection.recv(*args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/OpenSSL/SSL.py", line 995, in recv
    self._raise_ssl_error(self._ssl, result)
  File "/usr/lib/python2.7/dist-packages/OpenSSL/SSL.py", line 851, in _raise_ssl_error
    raise ZeroReturnError()
ZeroReturnError

Storing debug log for failure in /root/.pip/pip.log

Is python 2.7 correct. I noticed I'm running ansible 1.7, while 1.9 is recommended, but I don't think that's what caused the error here.

@drybjed
Copy link
Member

drybjed commented Aug 6, 2015 via email

@leviwheatcroft
Copy link
Author

Ok so for my first issue, debops-update returning no such file or directory, yes cloning the git repo solved this problem.

For the second issue, python ZeroReturnError(), I resolved that by:

sudo apt-get install python-dev
sudo pip install --upgrade pyOpenSSL

I rarely use python, so I installed python on this machine (Debian Jessie) just a few days ago for the first time to play around with ansible. The pyOpenSSL package installed by default was 0.14, and updating it to 0.15 solved the ZeroReturnError problem.

Thanks so much for your advice!

@drybjed
Copy link
Member

drybjed commented Aug 7, 2015

Good to know you fixed the issue. I wonder if it's repeatable and should requirements reflect that pyOpenSSL needs to be updated on Jessie, however I'm running Ansible on Ubuntu Trusty machine where I have 0.13 installed, and no issues. Perhaps it's related to this specific 0.14 version of pyOpenSSL.

@leviwheatcroft
Copy link
Author

Can confirm pyOpenSSL needs to be updated in this fashion from a clean install of debian 8.1

edit: actually you have to uninstall pyOpenSSL with apt first before you can upgrade it with pip:

sudo apt-get remove python-openssl
sudo pip install pyOpenSSL

@thiagotalma
Copy link
Contributor

@drybjed I had the same problem no such file or directory

I discovered it was the lack of git package. You forgot to include it as prerequisites.

@violuke
Copy link
Contributor

violuke commented May 15, 2016

Yes, as @thiagotalma said, this is caused by the git package being missing. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants