# How to configure Kubernetes yaml files to work behind a proxy

**URL:** <https://forum.weaviate.io/t/how-to-configure-kubernetes-yaml-files-to-work-behind-a-proxy/21862>\
**Category:** Support\
**Tags:** technical\
**Created:** [August 20, 2025, 12:50pm UTC](https://forum.weaviate.io/t/how-to-configure-kubernetes-yaml-files-to-work-behind-a-proxy/21862 "2025-08-20T12:50:09Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ashu](https://avatars.discourse-cdn.com/v4/letter/a/4bbf92/32.png) [@Ashu](https://forum.weaviate.io/u/Ashu)\
**Post date:** [August 20, 2025, 12:50pm UTC](https://forum.weaviate.io/t/how-to-configure-kubernetes-yaml-files-to-work-behind-a-proxy/21862/1 "2025-08-20T12:50:09Z")

</div>

### Description

If we add https\_proxy in kubernetes, node is not starting and no peers found, election aborted. Without proxy we are not able to hit openai services. How to configure deployment.yaml to remedy this. This is a single-node setup.

### Server Setup Information

- Weaviate Server Version: 1.31.5
- Deployment Method: Kubernetas
- Multi Node? Number of Running Nodes: Single node
- Client Language and Version: Python client v4
- Multitenancy?: No

### Any additional Information

containers:  
- args:  
- --host  
- 0.0.0.0  
- --port  
- “8080”  
- --scheme  
- http  
env:  
- name: AUTHENTICATION\_ANONYMOUS\_ACCESS\_ENABLED  
value: “true”  
- name: CLUSTER\_HOSTNAME  
value: node1  
- name: DEFAULT\_VECTORIZER\_MODULE  
value: none  
- name: ENABLE\_MODULES  
value: text2vec-cohere,text2vec-huggingface,text2vec-palm,text2vec-openai,generative-openai,generative-cohere,generative-palm,ref2vec-centroid,reranker-cohere,qna-openai  
- name: PERSISTENCE\_DATA\_PATH  
value: /var/lib/weaviate  
- name: BACKUP\_FILESYSTEM\_PATH  
value: /tmp/backups  
- name: QUERY\_DEFAULTS\_LIMIT  
value: “25”  
- name: https\_proxy  
value: [http://120.0.0.1:8080/](http://120.0.0.1:8080/)  
image: semitechnologies/weaviate:1.31.5-68c0927.amd64  
imagePullPolicy: IfNotPresent  
name: weaviate  
ports:  
- containerPort: 8080  
protocol: TCP  
- containerPort: 50051  
protocol: TCP  
resources: {}

---

<div class="post-metadata">

**Author:** ![Shahin](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.weaviate.io/shahin/32/7944_2.png) [@Shahin](https://forum.weaviate.io/u/Shahin)\
**Post date:** [August 21, 2025, 9:06am UTC](https://forum.weaviate.io/t/how-to-configure-kubernetes-yaml-files-to-work-behind-a-proxy/21862/2 "2025-08-21T09:06:13Z")

</div>

Hey @Ashu

Welcome to our community—it’s lovely to have you here 🤗

I’m not an expert in proxies, but I did look into this, and as probably same as ["attempt to join and failed" when using PERSISTENCE\_DATA\_PATH env with efs storage - #3 by franz\_hals](https://forum.weaviate.io/t/attempt-to-join-and-failed-when-using-persistence-data-path-env-with-efs-storage/10702/3) by other community member, you can try setting the **no\_proxy** environment variable to exclude local addresses and the pod/container’s own IPs from being proxied. This way, Weaviate’s internal communication won’t go through the proxy, while external requests (like to OpenAI) still will.

Try adding a no\_proxy variable alongside your https\_proxy. For a single-node setup, you’d typically want to exclude at least localhost, 127.0.0.1, and your pod’s own IP range.

I will also tag my colleague @DudaNogueira who is experienced with proxies in case I missed on any critical point in the above.

Have you tried that already?

Best regards,

Mohamed Shahin  
Weaviate Support Engineer  
(Ireland, UTC±00:00/+01:00)

---

<div class="post-metadata">

**Author:** ![Ashu](https://avatars.discourse-cdn.com/v4/letter/a/4bbf92/32.png) [@Ashu](https://forum.weaviate.io/u/Ashu)\
**Post date:** [August 22, 2025, 12:49pm UTC](https://forum.weaviate.io/t/how-to-configure-kubernetes-yaml-files-to-work-behind-a-proxy/21862/3 "2025-08-22T12:49:26Z")

</div>

Hi @Shahin,

Thanks for the suggestion. I have tried adding the no\_proxy the above issue (no peers found, election aborted), this seems to be resolved. But getting another error i.e. not part of a stable configuration or a non-voter, not triggering a leader election.

containers:

- args:
- –host
- 0.0.0.0
- –port
- “8080”
- –scheme
- http  
env:
- name: AUTHENTICATION\_ANONYMOUS\_ACCESS\_ENABLED  
value: “true”
- name: CLUSTER\_HOSTNAME  
value: node1
- name: DEFAULT\_VECTORIZER\_MODULE  
value: none
- name: ENABLE\_MODULES  
value: text2vec-cohere,text2vec-huggingface,text2vec-palm,text2vec-openai,generative-openai,generative-cohere,generative-palm,ref2vec-centroid,reranker-cohere,qna-openai
- name: PERSISTENCE\_DATA\_PATH  
value: /var/lib/weaviate
- name: BACKUP\_FILESYSTEM\_PATH

value: /tmp/backups

- name: QUERY\_DEFAULTS\_LIMIT  
value: “25”
- name: https\_proxy  
value: [http://#.#.#.#:8080/](http://120.0.0.1:8080/)

-name: no\_proxy

value: #.#.#.#/16, localhost, .svc,.svc.cluster.local,kubernetes.default  
image: semitechnologies/weaviate:1.31.5-68c0927.amd64  
imagePullPolicy: IfNotPresent  
name: weaviate  
ports:

- containerPort: 8080  
protocol: TCP
- containerPort: 50051  
protocol: TCP  
resources: {}

Best Regards,  
Ashvini Kumar

---

<div class="post-metadata">

**Author:** ![Shahin](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.weaviate.io/shahin/32/7944_2.png) [@Shahin](https://forum.weaviate.io/u/Shahin)\
**Post date:** [August 22, 2025, 1:51pm UTC](https://forum.weaviate.io/t/how-to-configure-kubernetes-yaml-files-to-work-behind-a-proxy/21862/4 "2025-08-22T13:51:00Z")

</div>

@Ashu your cluster is a single node so leader errors and warnings shall be ignored since your cluster is not multi-node setup.

The cluster should be reachable and fine, right?

Additionally, I would say please upgrade your cluster to 1.32.4 (latest).

Best regards,

Mohamed Shahin  
Weaviate Support Engineer  
(Ireland, UTC±00:00/+01:00)

---

<div class="post-metadata">

**Author:** ![Ashu](https://avatars.discourse-cdn.com/v4/letter/a/4bbf92/32.png) [@Ashu](https://forum.weaviate.io/u/Ashu)\
**Post date:** [August 26, 2025, 5:45am UTC](https://forum.weaviate.io/t/how-to-configure-kubernetes-yaml-files-to-work-behind-a-proxy/21862/5 "2025-08-26T05:45:23Z")

</div>

Hi @Shahin ,

I have tried with suggested changes but still the same issue persist, as after adding no\_proxy has no effect.

In this single node setup, if I remove https\_proxy the weaviate container is running and leader is held & won and able to use the DB. But if i am removing https\_proxy won’t able to use openai models.

And with https\_proxy, the leader election is not triggering.

Thanks and Regards,

Ashvini Kumar

---

<div class="post-metadata">

**Author:** ![andrewisplinghoff](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.weaviate.io/andrewisplinghoff/32/1853_2.png) [@andrewisplinghoff](https://forum.weaviate.io/u/andrewisplinghoff)\
**Post date:** [August 28, 2025, 12:24pm UTC](https://forum.weaviate.io/t/how-to-configure-kubernetes-yaml-files-to-work-behind-a-proxy/21862/6 "2025-08-28T12:24:25Z")

</div>

> [@Ashu](#):
>
> value: #.#.#.#/16, localhost, .svc,.svc.cluster.local,kubernetes.default

This looks a bit weird, no\_proxy is supposed to contain individual domains, domain suffixes or IPs. Giving an IP range such as #.#.#.#/16 is not supported AFAIK. If possible, you could try adding all possible IPs individually: [bash - Set a network range in the no\_proxy environment variable - Unix & Linux Stack Exchange](https://unix.stackexchange.com/a/23478)

I also see there are spaces within your value (after commas), that might also be a problem, I would advise to remove them.
