Skip to content

Instantly share code, notes, and snippets.

@rgregg
Created July 19, 2018 19:16
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save rgregg/8b4f426512f7e79eb5c6e6d498266154 to your computer and use it in GitHub Desktop.
Save rgregg/8b4f426512f7e79eb5c6e6d498266154 to your computer and use it in GitHub Desktop.
How to extract LICENSES from docker image
  1. Start the container

    $ docker run -d {docker image}
    f05ad96e2570da12c27784d0d4752c99269e25713bb8565c287eb52d8f97573f
  2. Extract the license from the container to standard out

    $ docker cp f05ad96e2570da12c27784d0d4752c99269e25713bb8565c287eb52d8f97573f:/LICENSES.txt -
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment