简体   繁体   中英

Dockerfile from Docker Hub repository

I'm trying to create Dockerfile for Centos 7 and python 2.7 I found one at the Docker Hub: https://hub.docker.com/r/centos/python-27-centos7 But I don't see any tutorial How to create Dockerfile using this image - I see pull command only

Actually I want to add some dependencies and python packages

So my question in general - if I found some suitable image on DockerHub - How to use it in my Dockerfile?

I just tried:

FROM python-27-centos7

But got next error:

failed to solve with frontend dockerfile.v0: failed to build LLB: failed to load cache key: pull access denied, repository does not exist or may require authorization: server message: insufficient_scope: authorization failed

It would help if you did this:

FROM centos/python-27-centos7

So my question in general - if I found some suitable image on DockerHub - How to use it in my Dockerfile?

It would be best if you used the full image name:

User/Repo:Tag

The default value for the tag is "latest"

FROM centos/python-27-centos7:latest

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM