Skip to content

Instantly share code, notes, and snippets.

@ikurni
Last active October 15, 2020 04:41
Show Gist options
  • Save ikurni/6b9957b37cbf49579f6b016d39d35de6 to your computer and use it in GitHub Desktop.
Save ikurni/6b9957b37cbf49579f6b016d39d35de6 to your computer and use it in GitHub Desktop.
Oc command to apply cluster wide proxy
oc -n openshift-cluster-version set env deploy cluster-version-operator HTTP_PROXY=http://proxy-server:port HTTPS_PROXY=http://proxy-server:port NO_PROXY=".cluster.local,.company.com,.svc,10.0.0.0/16,10.32.0.0/14,10.36.0.0/16,127.0.0.1,api-int.dc.company.com,etcd-0.dc.company.com,etcd-1.dc.company.com,etcd-2.dc.company.com,localhost"
apiVersion: config.openshift.io/v1
kind: Proxy
metadata:
name: cluster
spec:
httpProxy: http://proxy-server:port
httpsProxy: http://proxy-server:port
noProxy: .company.com,mirror.openshift.com
trustedCA:
name: ""
status:
httpProxy: http://proxy-server:port
httpsProxy: http://proxy-server:port
noProxy: .cluster.local,.company.com,.svc,10.0.0.0/16,10.32.0.0/14,10.36.0.0/16,127.0.0.1,api-int.dc.company.com,etcd-0.dc.company.com,etcd-1.dc.company.com,etcd-2.dc.company.com,localhost,mirror.openshift.com
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment