Hi Abdirahman,
One small doubt . In kamailio IMS server, we have dns configurations
using bind9 with SRV records pointing a port for every ip address .
My domain name is
Pcscf.sip.example.com:4060
Icscf.sip.example.com:4070
scscf.sip.example.com:4080
So this is how the dns server will be in my case.
The same domain names are configured as alias in my respective cscf
config files.
When you talk about nameserver . How this has to be configured using
coredns/kubedns setting clusterIP : None
How this can be done from your point of view using coredns.
Kindly help me with this
Thanks,
Pavithra
On Thu, Aug 27, 2020, 11:55 PM David Villasmil <
david.villasmil.work(a)gmail.com> wrote:
Interesting! I’ll be testing that very soon! Many
thanks!!
On Thu, 27 Aug 2020 at 14:53, Abdirahman A. Osman <
abdirahman.osm(a)gmail.com> wrote:
> Hi David,
>
> Yes that is right, so when you set to ClusterIP:none, it turns the
> services into a headless services. and the DNS will resolve to a single
> POD, instead of a group of PODs, and you can reach every POD through the
> DNS. IPs may change but the DNS will stay fixed when you use Statefullset,
> as you need a fixed DNS name for the pod. If you use Deployment you get a
> randomly generated name, which is not what you want.
>
>
> Abdirahman
>
>
>
> On Thu, 27 Aug 2020 at 08:06, David Villasmil <
> david.villasmil.work(a)gmail.com> wrote:
>
>> Hello Abdirahman,
>>
>> Thanks for replying.
>>
>> Do you mean if I create a service for the label selector of what’s
>> running in the pod, but ser ClusterIP: None, when another pod tries to
>> resolve that service, it will get the actual IP of the running POD?
>>
>>
>> On Wed, 26 Aug 2020 at 18:02, Abdirahman A. Osman <
>> abdirahman.osm(a)gmail.com> wrote:
>>
>>> Hi Pavithra,
>>>
>>> Since POD IPs change, you have to rely on DNS records. To have a
>>> fixed DNS name like
>>>
>>> kamailio.kamalio-service.namespace.svc.cluster.local
>>>
>>>
>>>
>>> for a pod you will have to use StatefullSet, so the pod DNS name
>>> doesn't change. Also you have to use Services and set it to ClusterIP:
>>> none, it will turn your pods to headless services and no load balancing is
>>> involved. and from my understanding you will be able to reach each POD
>>> directly through the DNS name.
>>>
https://kubernetes.io/docs/concepts/services-networking/service/
>>>
>>> and don't forget to set your /etc/resolv.conf with the kubedns IP
>>> address.
>>>
>>> Abdirahman
>>>
>>>
>>>
>>> On Wed, 26 Aug 2020 at 12:45, Pavithra Mohanraja <
>>> pavimohan3004(a)gmail.com> wrote:
>>>
>>>> Hi Abdirahman,
>>>>
>>>> Do you mean , if I set clusterIP as None, then kubedns server will
>>>> be pointing to pod ip so that kubedns/coredns will use pod ip for pod
>>>> communication instead of service IP.
>>>>
>>>>
>>>> Is my understanding correct? From your explanation.
>>>>
>>>> If this is the case, pod ip will be changing whenever I launch the
>>>> pods . How that can be resolved.
>>>>
>>>> Could you kindly helo me with this?
>>>>
>>>>
>>>> Thanks,
>>>> Pavithra
>>>>
>>>> On Wed, Aug 26, 2020, 9:26 PM Abdirahman A. Osman <
>>>> abdirahman.osm(a)gmail.com> wrote:
>>>>
>>>>> David,
>>>>>
>>>>>
>>>>>
>>>>> Assuming those are pod ips. Using services doesn’t work
>>>>>>
>>>>>> since the dns name will resolve to a k8s service ip and no the
>>>>>> actual
>>>>>>
>>>>>> pod running the service.
>>>>>>
>>>>>
>>>>> If you set *clusterIP: None* in the services, you will get POD
>>>>> IP.
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> Abdirahman
>>>>>
>>>>>
>>>>>
>>>>> On Wed, 26 Aug 2020 at 10:48, Pavithra Mohanraja <
>>>>> pavimohan3004(a)gmail.com> wrote:
>>>>>
>>>>>> Hi,
>>>>>> Thanks for the answers.
>>>>>> @David has got my question.
>>>>>>
>>>>>> I have a seperate dns server running in my pcscf pod . So in my
>>>>>> /etc/resolv.conf file , I would be configuring
>>>>>> nameserver <pcscf pod ip>
>>>>>> in all other cscf pods as well for communication.
>>>>>>
>>>>>>
>>>>>>
>>>>>> My question here is how to change the dns server pointing to
>>>>>> cluster ip so that my domain name for IMS will be pointing to
coredns
>>>>>> itself. It will restrict me from using pod IP since it changes
everytime.
>>>>>>
>>>>>>
>>>>>> @David, can you please tell me the last two lines briefly. I did
>>>>>> not get it.how you configured . You mean to say still you are
using pod Ip.
>>>>>>
>>>>>>
>>>>>> On Wed, Aug 26, 2020, 8:02 PM David Villasmil <
>>>>>> david.villasmil.work(a)gmail.com> wrote:
>>>>>>
>>>>>>> I’ve been trying to figure this out as well.
>>>>>>> I haven’t yet found a way of publishing to kube-dns the pod
IP
>>>>>>> of the running service.
>>>>>>>
>>>>>>> I.e.:
>>>>>>> kamailio.whatever.local on ip 10.0.0.1
>>>>>>> Rtpengine.whatever.local on ip 10.0.0.2
>>>>>>> Appserver.whatever.local on 10.0.0.3
>>>>>>>
>>>>>>> Assuming those are pod ips. Using services doesn’t work
since
>>>>>>> the dns name will resolve to a k8s service ip and no the
actual pod running
>>>>>>> the service.
>>>>>>>
>>>>>>> Assigning IPs hardcoded doesn’t work either since it might
>>>>>>> change if the docker changes pod. I can have multiple modes
on which a
>>>>>>> service can run, but only one service (kamailio, rtpengine,
appserver, etc)
>>>>>>> will run on a given pod.
>>>>>>>
>>>>>>> On Wed, 26 Aug 2020 at 15:18, Abdirahman A. Osman <
>>>>>>> abdirahman.osm(a)gmail.com> wrote:
>>>>>>>
>>>>>>>> Hi
>>>>>>>>
>>>>>>>> Pavithra
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> You can use the kubedns/CoreDNS of the kubernetes cluster
to
>>>>>>>> resolve Internal DNS records of the pods.To assign DNS
records for each POD
>>>>>>>> you have to deploy a service and set the ClusterIP: none.
and the dns
>>>>>>>> record will be something like
>>>>>>>> kamailio.kamalio-service.platform.svc.cluster.local
>>>>>>>> which is the
podname.servicename.namespace.svc.cluster.local
>>>>>>>>
>>>>>>>> In the resolve.conf you will put the kubeDNS/CoreDNS IP
as the
>>>>>>>> nameserver. You can set this in the kubernetes manifest
file
>>>>>>>>
>>>>>>>> dnsPolicy: "None"
>>>>>>>> dnsConfig:
>>>>>>>> nameservers:
>>>>>>>> - 10.34.0.1 (
>>>>>>>>
>>>>>>>> kubeDNS/CoreDNS )
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Abdirahman
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> On Tue, 25 Aug 2020 at 15:34, Sergey Safarov <
>>>>>>>> s.safarov(a)gmail.com> wrote:
>>>>>>>>
>>>>>>>>> I am not k8s developer.
>>>>>>>>> So cannot provide detailed instructions. Just my
point of view.
>>>>>>>>>
>>>>>>>>> You can look
>>>>>>>>>
https://kubernetes.io/docs/concepts/extend-kubernetes/operator/
>>>>>>>>>
>>>>>>>>>
https://www.magalix.com/blog/creating-custom-kubernetes-operators
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Tue, Aug 25, 2020 at 7:41 PM Pavithra Mohanraja
<
>>>>>>>>> pavimohan3004(a)gmail.com> wrote:
>>>>>>>>>
>>>>>>>>>> Hi,
>>>>>>>>>>
>>>>>>>>>> It would be helpful if you could elaborate what
has to be
>>>>>>>>>> done for kubernetes pods when you mention sip
ingress
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Thanks,
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Pavithra
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On Tue, Aug 25, 2020, 9:32 PM Sergey Safarov
<
>>>>>>>>>> s.safarov(a)gmail.com> wrote:
>>>>>>>>>>
>>>>>>>>>>> Lot of issues with static IP in Kubernetes.
>>>>>>>>>>>
>>>>>>>>>>> Looks as need deploy "sip ingress"
like "HTTP/HTTPS ingress"
>>>>>>>>>>> and then route calls to pods.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On Tue, Aug 25, 2020 at 4:40 PM Pavithra
Mohanraja <
>>>>>>>>>>> pavimohan3004(a)gmail.com> wrote:
>>>>>>>>>>>
>>>>>>>>>>>> Hi,
>>>>>>>>>>>>
>>>>>>>>>>>> I am configuring kamailio IMS as
kubernetes pods .
>>>>>>>>>>>> so each component will be configured as
separate pod .
>>>>>>>>>>>> In order to establish a connection
between pods , I am
>>>>>>>>>>>> configuring bind9 dns server in pcscf pod
itself. Communication is
>>>>>>>>>>>> happening via Pod IP address.
>>>>>>>>>>>>
>>>>>>>>>>>> Is there any possibility to have the
communication using
>>>>>>>>>>>> cluster IP . If anybody is aware of
kubernetes, Please help me in this
>>>>>>>>>>>> regard.
>>>>>>>>>>>>
>>>>>>>>>>>> I have my /etc/resolv.conf file in pods
with
>>>>>>>>>>>> nameserver <clusterIP>
>>>>>>>>>>>> search <cluster-dns-domain-name>
>>>>>>>>>>>>
>>>>>>>>>>>> Please help.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Thanks,
>>>>>>>>>>>> Pavithra
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
_______________________________________________
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Kamailio (SER) - Users Mailing List
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> sr-users(a)lists.kamailio.org
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
_______________________________________________
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> Kamailio (SER) - Users Mailing List
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> sr-users(a)lists.kamailio.org
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> _______________________________________________
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Kamailio (SER) - Users Mailing List
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> sr-users(a)lists.kamailio.org
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>> _______________________________________________
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Kamailio (SER) - Users Mailing List
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> sr-users(a)lists.kamailio.org
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>> _______________________________________________
>>>>>>>>
>>>>>>>> Kamailio (SER) - Users Mailing List
>>>>>>>>
>>>>>>>> sr-users(a)lists.kamailio.org
>>>>>>>>
>>>>>>>>
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>>>>>>>>
>>>>>>>> --
>>>>>>> Regards,
>>>>>>>
>>>>>>> David Villasmil
>>>>>>> email: david.villasmil.work(a)gmail.com
>>>>>>> phone: +34669448337
>>>>>>>
>>>>>>>
>>>>>>> _______________________________________________
>>>>>>>
>>>>>>>
>>>>>>> Kamailio (SER) - Users Mailing List
>>>>>>>
>>>>>>>
>>>>>>> sr-users(a)lists.kamailio.org
>>>>>>>
>>>>>>>
>>>>>>>
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>
>>> --
>> Regards,
>>
>> David Villasmil
>> email: david.villasmil.work(a)gmail.com
>> phone: +34669448337
>>
>>
>>
>
> --
Regards,
David Villasmil
email: david.villasmil.work(a)gmail.com
phone: +34669448337