Skip to content

Commit 475bd72

Browse files
committed
docs(kwctl,policy-server): Mention proxy env vars on readmes
Signed-off-by: Víctor Cuadrado Juan <vcuadradojuan@suse.de>
1 parent 3963e83 commit 475bd72

File tree

2 files changed

+25
-0
lines changed

2 files changed

+25
-0
lines changed

docs/kwctl/README.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,21 @@ This value can be obtained using a tool like [crane](https://github.com/google/g
9898
crane digest ghcr.io/kubewarden/policies/psp-capabilities:v0.1.6
9999
```
100100

101+
#### Using a proxy
102+
103+
`kwctl` respects standard proxy environment variables when downloading policies:
104+
105+
- `HTTP_PROXY` or `http_proxy`: proxy server for HTTP requests
106+
- `HTTPS_PROXY` or `https_proxy`: proxy server for HTTPS requests
107+
- `NO_PROXY` or `no_proxy`: comma-separated list of hosts to exclude from proxying
108+
109+
Example:
110+
111+
```console
112+
export HTTPS_PROXY=http://proxy.example.com:8080
113+
kwctl pull registry://ghcr.io/kubewarden/policies/psp-capabilities:latest
114+
```
115+
101116
### Run
102117

103118
`kwctl` can be used to run a policy locally, outside of Kubernetes. This can be used

docs/policy-server/README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,16 @@ depends on the URL format provided by the user:
7171
- `registry://localhost:5000/project/artifact:some-version` download the policy
7272
from a OCI registry. The policy must have been pushed as an OCI artifact
7373

74+
### Using a proxy
75+
76+
When downloading policies from remote locations, `policy-server` respects standard proxy environment variables:
77+
78+
- `HTTP_PROXY` or `http_proxy`: proxy server for HTTP requests
79+
- `HTTPS_PROXY` or `https_proxy`: proxy server for HTTPS requests
80+
- `NO_PROXY` or `no_proxy`: comma-separated list of hosts to exclude from proxying
81+
82+
These environment variables should be set in the policy-server container environment.
83+
7484
### Policy Group
7585

7686
Multiple policies can be grouped together and are evaluated using a user provided boolean expression.

0 commit comments

Comments
 (0)