Contents
Table of Contents | ||||
---|---|---|---|---|
|
...
Prepared By | Reviewed By | Date | Document Version |
Fernando Cisneros | Artem Kalaitan | 225-JulyAug-2022 | V 1 |
Introduction
This document gives the information about how to configure k3s with proxy.
...
Open the file
/etc/systemd/system/k3s.service.env
and append the following lines:Code Block http_proxy="$PROXY_IP" https_proxy="$PROXY_IP" no_proxy="$NODE_IP,localhost,127.0.0.0/8,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16,.svc,.cluster.local"
Restart k3s
systemctl restart k3s.service
Go to the Rancher dashboard
Cluster Management > Clusters and click on Edit Config for your cluster:
Go to Advanced Options:
Configure the following Agent Environment Variables and press Save:
Code Block HTTP_PROXY: $PROXY_IP HTTPS_PROXY: $PROXY_IP NO_PROXY: $NODE_IP,localhost,127.0.0.0/8,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16,.svc,.cluster.local
Run the Rancher registration command:
kubectl apply -f https://....yaml
End Of Document