docker - Create image-stream on image from private registry on OpenShift -


i've set openshift origin 1.1.3 cluster. i'm pulling images private registry. registry 'insecure'. has self-signed certificates , credentials authenticate. i'm able perform docker login , pull image manually on node.

the problem node can access image. when i'm scaling pod (based on image), replica's run on specific node. other nodes not able pull or use image.

so want create image-stream image:

oc import-image --insecure=true ec2-xxx:5000/image  but:       message: may not have access docker image "ec2-xxx:5000/image"       reason: unauthorized 

i read creating secret. created it:

oc secrets new-dockercfg mysecret --docker-server=ec2-xxx:5000 --docker-username=*** --docker-password=*** --docker-email=any@mail.com 

how have add secret image-stream? , right approach?

@cloudnoob answer helped me lot. main problem i've created secret in wrong way. saw after starting openshift master loglevel 5.

unable find secret match https://ec2-xxx:5000/v2/test/image/manifests/83  

so had create secret https (it's called insecure selfsigned certificates it's using https):

oc secrets new-dockercfg mysecret --docker-server=https://ec2-xxx:5000 --docker-username=*** --docker-password=*** --docker-email=any@mail.com 

after step had perform steps of cloudnoob. adding secrets service accounts. after import succes.


Comments

Popular posts from this blog

java - Suppress Jboss version details from HTTP error response -

gridview - Yii2 DataPorivider $totalSum for a column -

Sass watch command compiles .scss files before full sftp upload -