Skip to content

Instantly share code, notes, and snippets.

Created June 17, 2020 15:49
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
What would you like to do?
Yumdownloader Dockerfile
# docker image to download yum rpms via dependencies
# these are the centos tags you can use below if you want to use a different version of centos
#latest, centos7, 7 (docker/Dockerfile)
#centos6, 6 (docker/Dockerfile)
#centos5, 5 (docker/Dockerfile)
#centos7.1.1503, 7.1.1503 (docker/Dockerfile)
#centos7.0.1406, 7.0.1406 (docker/Dockerfile)
#centos6.7, 6.7 (docker/Dockerfile)
#centos6.6, 6.6 (docker/Dockerfile)
#centos5.11, 5.11 (docker/Dockerfile)
# For more information, check the website below:
FROM centos:7
# install yum-utils for the yumdownloader command
# if you needed additional repositories you could do that here
RUN yum install -y yum-utils
# create my rpms directory (mount your local volume to this path)
RUN mkdir /rpms
VOLUME /rpms
ENTRYPOINT ["yumdownloader", "--destdir=/rpms", "--resolve"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment