<p>I have uploaded some code on github: <a href="https://github.com/darkcloudi/helm-camunda-postgres" rel="nofollow noreferrer">https://github.com/darkcloudi/helm-camunda-postgres</a></p>

<p>Running the following commands deploys the two charts (Note the set is required to allow the postgres db to be deployed, i've disabled it by default, as camunda comes with its own DB, i'm trying to configure it to use postgres): </p>

<pre><code>helm install dev ./camunda-install --set tags.postgres=true
</code></pre>

<p>You will see that its all looking good:</p>

<pre><code>NAME                              READY   STATUS      RESTARTS   AGE
pod/dev-camunda-67f487dcd-wjdfr   1/1     Running     0          36m
pod/dev-camunda-test-connection   0/1     Completed   0          45h
pod/postgres-86c565898d-h5tf2     1/1     Running     0          36m

NAME                   TYPE        CLUSTER-IP       EXTERNAL-IP   PORT(S)          AGE
service/dev-camunda    NodePort    10.106.239.96    &lt;none&gt;        8080:30000/TCP   36m
service/dev-postgres   NodePort    10.108.235.106   &lt;none&gt;        5432:30001/TCP   36m
service/kubernetes     ClusterIP   10.96.0.1        &lt;none&gt;        443/TCP          4d19h
</code></pre>

<p>If I either use the 10.108.x.x ip or the minikube ip 192.168.64.2 I get the same error below, I can connect to tomcat using <a href="http://camunda.minikube.local/" rel="nofollow noreferrer">http://camunda.minikube.local/</a> or <a href="http://192.168.64.2:30000/" rel="nofollow noreferrer">http://192.168.64.2:30000/</a> so was wondering where I might be going wrong when attempting to connect to postgres.</p>

<pre><code>kubectl exec -it postgres-86c565898d-h5tf2 --  psql -h 10.108.235.106 -U admin --password -p 30001 camunda
Password:
</code></pre>

<p>psql: error: could not connect to server: could not connect to server: Connection timed out
        Is the server running on host "10.108.235.106" and accepting
        TCP/IP connections on port 30</p>

<pre><code>kubectl describe svc dev-postgres
Name: dev-postgres
Namespace: default
Labels: app.kubernetes.io/managed-by=Helm
name=dev-postgres
Annotations:  meta.helm.sh/release-name: dev
meta.helm.sh/release-namespace: default
Selector:   app=dev-postgres,name=dev-postgres
Type: NodePort
IP:  10.108.235.106
Port:      postgres-http  5432/TCP
TargetPort:   5432/TCP
NodePort: postgres-http  30001/TCP
Endpoints:   &lt;none&gt;
Session Affinity:  None
External Traffic Policy:  Cluster
Events: &lt;none&gt;
</code></pre>

<p><a href="https://github.com/darkcloudi/helm-camunda-postgres/blob/master/camunda-install/charts/postgres/templates/postgres.yaml" rel="nofollow noreferrer">https://github.com/darkcloudi/helm-camunda-postgres/blob/master/camunda-install/charts/postgres/templates/postgres.yaml</a></p>

sam
<p>Since you are accessing it from within the cluster you should use the ClusterIP <code>10.108.235.106</code> and port <code>5432</code>.</p>

<p>If you wan to access it from outside the cluster then you can use Node IP <code>192.168.64.2 and NodePort 30001</code></p>

<p>Port <code>30001</code> is listening on the node VM and container is listening on port <code>5432</code>.So you can not access it via port <code>30001</code> from within the cluster.</p>

<p>Edit: </p>

<p>The <code>Endpoints</code> is empty on the service. This is because the label selector on the service is selecting pods with labels <code>app=dev-postgres,name=dev-postgres</code> but the pods don't have that label.</p>
