question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

dfimage looks broken

workaround: use https://github.com/mrhavens/Dedockify

similar to #35

imageName=xxx/yyy:latest
docker pull $imageName
docker images # -> get image ID
imageId=zzzzzzzzzz

docker run --rm -v /var/run/docker.sock:/var/run/docker.sock ghcr.io/laniksj/dfimage $imageId
Traceback (most recent call last):
  File "/root/entrypoint.py", line 56, in <module>
    __main__ = MainObj()
  File "/root/entrypoint.py", line 16, in __init__
    self._get_image(argv[-1])
  File "/root/entrypoint.py", line 32, in _get_image
    raise ImageNotFound("Image {} not found\n".format(repo_tag))
__main__.ImageNotFound: Image zzzzzzzzzz not found

# compare: dedockify
docker run --rm -v /var/run/docker.sock:/var/run/docker.sock mrhavens/dedockify $imageId
# -> ok. dockerfile is printed to stdout

# compare: dockerfile-from-image
docker run --rm -v /var/run/docker.sock:/var/run/docker.sock centurylink/dockerfile-from-image $imageName
/usr/lib/ruby/gems/2.2.0/gems/docker-api-1.24.1/lib/docker/connection.rb:42:in `rescue in request': 400 Bad Request: malformed Host header (Docker::Error::ClientError)

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
LanikSJcommented, Jan 19, 2022
docker run --rm -v /var/run/docker.sock:/var/run/docker.sock ghcr.io/laniksj/dfimage ruby:latest 
Traceback (most recent call last):
  File "/root/entrypoint.py", line 56, in <module>
    __main__ = MainObj()
  File "/root/entrypoint.py", line 16, in __init__
    self._get_image(argv[-1])
  File "/root/entrypoint.py", line 32, in _get_image
    raise ImageNotFound("Image {} not found\n".format(repo_tag))
__main__.ImageNotFound: Image ruby:latest not found

You’ll need to have done a docker pull on ruby:latest before running the above command.

docker pull ruby:latest
docker run --rm -v /var/run/docker.sock:/var/run/docker.sock ghcr.io/laniksj/dfimage ruby:latest

ghcr.io/laniksj/dfimagedfimage

docker run --rm -v /var/run/docker.sock:/var/run/docker.sock dfimage ruby:latest
Unable to find image 'dfimage:latest' locally
docker: Error response from daemon: pull access denied for dfimage, repository does not exist or may require 'docker login': denied: requested access to the resource is denied.

That won’t work since the docker hub image isn’t hosted on docker.io namespace:

docker pull laniksj/dfimage

if you want the image that’s no longer being updated and doesn’t have the latest changes.

docker pull dfimage Using default tag: latest Error response from daemon: pull access denied for dfimage, repository does not exist or may require ‘docker login’: denied: requested access to the resource is denied

See above.

0reactions
LanikSJcommented, Jan 19, 2022

can we catch __main__.ImageNotFound: Image ruby:latest not found and print something like “please run: docker pull ruby:latest”?

the uncaught exception makes it look like a bug

That’s a good idea I’ll look into adding that to the project.

Read more comments on GitHub >

github_iconTop Results From Across the Web

404 not found Images | Free Vectors, Stock Photos & PSD
Find & Download Free Graphic Resources for 404 Not Found. 62000+ Vectors, Stock Photos & PSD files. ✓ Free for commercial use ✓...
Read more >
How to fix image not showing in an HTML page
One reason for images not showing up on a website is because the browser or the server cache still serving the old HTML...
Read more >
Image Not Found, When The Image Is Right There? [duplicate]
png' found in working directory 'C:\Users\chizl\Documents'. The file is in the exact same directory as the images! Please help. (also, I want ...
Read more >
Why is there a 'File not found' image on my post?
The ubiquitous File not found image, explained: This image will appear when IFTTT is set up to post an image or a file,...
Read more >
Why am I getting an “Image not found” error?
The reason that you're getting this error generally cannot be determined without specific information. However, the answer is typically that ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found