You need to setup an ImageChange trigger in your DC that points to a tag at your imagestream https://docs.openshift.org/latest/dev_guide/deployments.html#image-change-trigger Otherwise, your deployment will try to pull the image from DockerHub (that's why you see the library prefix)
On Wed, Feb 17, 2016 at 7:10 PM, Derek Anderson < [email protected]> wrote: > I’m trying to pull an image from a private docker registry and deploy it > as an open shift application. Here is my ImageStream/DeploymentConfig: > > - kind: ImageStream > apiVersion: v1 > metadata: > name: lmp > spec: > dockerImageRepository: registry.localdomain/app/lmp > > - kind: DeploymentConfig > apiVersion: v1 > metadata: > name: lmp > spec: > strategy: > type: Rolling > rollingParams: > updatePeriodSeconds: 1 > intervalSeconds: 1 > timeoutSeconds: 120 > replicas: 4 > selector: > name: lmp > template: > metadata: > labels: > name: lmp > spec: > containers: > - name: lmp > image: lmp:production > ports: > - containerPort: 8080 > protocol: TCP > > > Here are the events I receive when trying to deploy: > > % oc get events > FIRSTSEEN LASTSEEN COUNT NAME KIND SUBOBJECT > REASON SOURCE MESSAGE > 19m 19m 1 lmp-1-340bs Pod > Scheduled {default-scheduler } Successfully assigned > lmp-1-340bs to openshift.eprize.net > 19m 18m 4 lmp-1-340bs Pod > spec.containers{lmp} Pulling {kubelet openshift.eprize.net} > pulling image "lmp:production" > 19m 18m 4 lmp-1-340bs Pod > spec.containers{lmp} Failed {kubelet openshift.eprize.net} > Failed to pull image "lmp:production": Error: image library/lmp:production > not found > 19m 18m 4 lmp-1-340bs Pod > FailedSync {kubelet openshift.eprize.net} Error syncing pod, > skipping: failed to "StartContainer" for "lmp" with ErrImagePull: "Error: > image library/lmp:production not found" > > 19m 17m 9 lmp-1-340bs Pod > spec.containers{lmp} BackOff {kubelet openshift.eprize.net} > Back-off pulling image "lmp:production" > 19m 17m 9 lmp-1-340bs Pod > FailedSync {kubelet openshift.eprize.net} Error syncing pod, > skipping: failed to "StartContainer" for "lmp" with ImagePullBackOff: > "Back-off pulling image \"lmp:production\"" > > 19m 19m 1 lmp-1-deploy Pod > Scheduled {default-scheduler } > Successfully assigned lmp-1-deploy to openshift.eprize.net > 19m 19m 1 lmp-1-deploy Pod > spec.containers{deployment} Pulled {kubelet > openshift.eprize.net} Container image > "openshift/origin-deployer:v1.1.2" already present on machine > 19m 19m 1 lmp-1-deploy Pod > spec.containers{deployment} Created {kubelet > openshift.eprize.net} Created container with docker id 2acc17cde431 > 19m 19m 1 lmp-1-deploy Pod > spec.containers{deployment} Started {kubelet > openshift.eprize.net} Started container with docker id 2acc17cde431 > 19m 19m 1 lmp-1 ReplicationController > FailedUpdate {deployer } > Error updating deployment derek/lmp-1 status to Pending > 19m 19m 1 lmp-1 ReplicationController > SuccessfulCreate {replication-controller } > Created pod: lmp-1-340bs > 17m 17m 1 lmp-1 ReplicationController > SuccessfulDelete {replication-controller } > Deleted pod: lmp-1-340bs > 19m 19m 1 lmp DeploymentConfig > DeploymentCreated {deploymentconfig-controller } > Created new deployment "lmp-1" for version 1 > 17m 17m 1 lmp DeploymentConfig > DeploymentScaled {deploymentconfig-controller } > Scaled deployment "lmp-1" from 1 to 0 > > > I’m not really sure why it’s trying to pull “library/lmp:production” as > that is not the repo name I am using. Any ideas? > > > _______________________________________________ > users mailing list > [email protected] > http://lists.openshift.redhat.com/openshiftmm/listinfo/users >
_______________________________________________ users mailing list [email protected] http://lists.openshift.redhat.com/openshiftmm/listinfo/users
