Coder Social home page Coder Social logo

Comments (8)

AXGKl avatar AXGKl commented on July 18, 2024 1

This downloads from v2, based on the moby one but w/o go (hardcoded amd64) and jq (this was hard) deps.

from bocker.

pwFoo avatar pwFoo commented on July 18, 2024

Should be fixed with the updated version here?
https://github.com/frohoff/bocker

from bocker.

pwFoo avatar pwFoo commented on July 18, 2024

But the bocker version with fixed pull from @frohoff has more dependencies!
https://github.com/frohoff/bocker/blob/master/bocker#L25

And download-frozen-image-v2 needs curl, go and jq...
https://github.com/moby/moby/blob/master/contrib/download-frozen-image-v2.sh#L11

Is there a way to download and extract docker images without so much dependencies?

from bocker.

tst2005 avatar tst2005 commented on July 18, 2024

if the go command is only use to detect the current OS, it could be replaced by uname (or uname -s).

from bocker.

pwFoo avatar pwFoo commented on July 18, 2024

@tst2005
Good point!
OS and ARCH

curl would be ok.

What's about jq (3,77MB binary linux64)

[EDIT]
Is there a simple bash script to download a docker image from a shell without dependencies?
Searched for a simple way to download an image...
[/EDIT]

from bocker.

tst2005 avatar tst2005 commented on July 18, 2024

IMHO,

  • s/without dependencies/with a few dependencies/
  • jq is a very powerfull utility to process json data. It is hard to deal with json without it. I don't know alternative or pure bash implementation

from bocker.

pwFoo avatar pwFoo commented on July 18, 2024

@AXGKl
You should add python in dependency check?
https://gist.github.com/AXGKl/9acf71366348e0ab0b85dd9258374792#file-docker_image_downloader-sh-L13

Python should be pre-installed with centos, but needs to be installed with other os variants?

from bocker.

NoseyNick avatar NoseyNick commented on July 18, 2024

I was about to suggest...

awk -F ': *' '$1 == "X-Docker-Token" { print $2 }'

needs to be case-insensitive:

awk -F ': *' 'tolower($1) == "x-docker-token" { print $2 }'

... but yeah nah, this goes deeper, needs the v2 API 😐

Can borrow from https://github.com/jjlin/docker-image-extract ?

from bocker.

Related Issues (15)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.