Hi Dilshani,

No you can use kubectl command to pull the image from private docker
registry, to do that you have to create a secret in k8s as[1] and refer
that in your yaml (i.e highlighted in [2])

[1] kubectl create secret docker-registry wso2registrykey --docker-server=
http://dockerhub.private.wso2.com/ --docker-username=xxxxx
--docker-password=xxxxxx --docker-email=xx...@wso2.com

[2]

apiVersion: v1

kind: ReplicationController

metadata:

  name: wso2am-api-key-manager

  labels:

    name: wso2am-api-key-manager

spec:

  replicas: 1

  selector:

    name: wso2am-api-key-manager

  template:

    metadata:

      labels:

        name: wso2am-api-key-manager

    spec:

      containers:

      -

        name: wso2am-api-key-manager

        image:
dockerhub.private.wso2.com/dimuthud-wso2-am-api-keymanager:1.10.0

        env:

        -

          name: KUBERNETES_MASTER_SKIP_SSL_VERIFICATION

          value: "true"

        -

          name: KUBERNETES_API_SERVER

          value: "http://192.168.19.45:8080";

        ports:

        -

          containerPort: 9763

          protocol: "TCP"

        -

          containerPort: 9443

          protocol: "TCP"

        -

          containerPort: 10397

          protocol: "TCP"

      imagePullSecrets:

      - name: registrypullsecret

Thanks,
Iqbal

On Wed, Oct 26, 2016 at 5:09 PM, Dilshani Subasinghe <dilsh...@wso2.com>
wrote:

> Hi Irham,
>
> I need a clarification on this. Do we have to pull every image manually?
> As I can see, while running the tests it will fail pulling due to
> authentication error. But still we can pull the same image manually and
> then it going to work.
>
> Any idea on fixing?
>
> Regards,
> Dilshani
>
> On Wed, Oct 26, 2016 at 5:01 PM, Dilshani Subasinghe <dilsh...@wso2.com>
> wrote:
>
>> Hi Irham,
>>
>> Thanks a lot for pointing out the solution. Problem solved.
>>
>> Regards,
>> Dilshani
>>
>> On Wed, Oct 26, 2016 at 4:01 PM, Irham Iqbal <iq...@wso2.com> wrote:
>>
>>> Hi Dilshani,
>>>
>>> Since you're pulling the image from private docker registry to your k8s
>>> node you have to configure your node refer mail[1]. Then you can check the
>>> image pulling manually(login to that node and docker pull).
>>>
>>>
>>> Thanks,
>>> Iqbal
>>>
>>> [1] WSO2 Private Docker Registry
>>>
>>> On Wed, Oct 26, 2016 at 3:43 PM, Dilshani Subasinghe <dilsh...@wso2.com>
>>> wrote:
>>>
>>>> Hi Devs,
>>>>
>>>> While configuring Kubernetes cluster, came up with an error in
>>>> Kubernetes pod.
>>>>
>>>> For the command "kubectl get pods", it list down results as follows:
>>>>
>>>> NAME                       READY     STATUS             RESTARTS   AGE
>>>> mysql-apim-db-1viwg    1/1         Running
>>>> 2          20h
>>>> mysql-govdb-qioee        1/1         Running
>>>> 2          20h
>>>> mysql-userdb-l8q8c       1/1         Running
>>>> 1          20h
>>>> wso2am-default-813fy    0/1       ImagePullBackOff          0
>>>> 20h
>>>>
>>>> When find the reason for "ImagePullBackOff ", identified following
>>>> error.
>>>>
>>>> Error response from daemon: Authentication is required: Get
>>>> https://dockerhub.private.wso2.com/v2/wso2am/manifests/1.10.0:
>>>> unauthorized: authentication required
>>>>
>>>> Any ideas/ suggestions to solve this error?
>>>>
>>>> --
>>>> Best Regards,
>>>>
>>>> Dilshani Subasinghe
>>>> Software Engineer - QA *|* WSO2
>>>> lean *|* enterprise *|* middleware
>>>>
>>>> Mobile : +94773375185
>>>> Blog    : dilshani.me
>>>>
>>>> <https://wso2.com/signature>
>>>>
>>>
>>>
>>>
>>> --
>>> Irham Iqbal
>>> Software Engineer
>>> WSO2
>>> phone: +94 777888452
>>> <http://wso2.com/signature>
>>>
>>>
>>
>>
>> --
>> Best Regards,
>>
>> Dilshani Subasinghe
>> Software Engineer - QA *|* WSO2
>> lean *|* enterprise *|* middleware
>>
>> Mobile : +94773375185
>> Blog    : dilshani.me
>>
>> <https://wso2.com/signature>
>>
>
>
>
> --
> Best Regards,
>
> Dilshani Subasinghe
> Software Engineer - QA *|* WSO2
> lean *|* enterprise *|* middleware
>
> Mobile : +94773375185
> Blog    : dilshani.me
>
> <https://wso2.com/signature>
>



-- 
Irham Iqbal
Software Engineer
WSO2
phone: +94 777888452
<http://wso2.com/signature>
_______________________________________________
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to