Setting Environment
Couchbase Cluster has 2 nodes with rebalancing…
and I set k8s DNS each nodes by REST API renaming Nodes for auto healing
But the problem is
when I try to use client python SDK through Loadbalancer Service from outside of k8s,
python SDK object “Cluster” has k8s DNS name.
So I want to try to get data from bucket, but SDK can’t not know real ip address and Connection failed.
I know temporary solution ( add dns address in hosts file )
But I think this is not good solution
for example, If a pod died, I need to change hosts file again for new pod address.
Or developing an application for getting IP address by dns… but need time and work
are there some good opinions in this situation?
for example, SDK returns real ip address (not k8s DNS )
That’s what I want that just simple and clear help.
But I think I can not use Operator
Because I am using Community Edition.
So…
One more question…
The reason why I connect to couchbase of container from outside of k8s is that I need to push data into couchbase by batch processing
Another solution I found…
I think I can use cbimport
cause I did data import through Web Console from outside of k8s
and I found a suggestion using cbimport for faster performance and example command.
is this right?
If it’s possible,
than I will just install couchbase for using cbimport and pushing data.
is it okay?
I’ve just tried above process with cbimport
but I got error like this:
JSON import failed: lookup couchbase-st-0.couchbase.namespace.svc.cluster.local:no such host
I think still need real ip of k8s DNS
so I wonder what it is that success importing data on web console