Skip to content

Commit 0aec75d

Browse files
committed
add READMEg
1 parent 05f980f commit 0aec75d

File tree

1 file changed

+42
-0
lines changed

1 file changed

+42
-0
lines changed

README.md

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# coder-xray
2+
3+
[![release](https://img.shields.io/github/v/tag/coder/coder-xray)](https://github.com/coder/coder-xray/pkgs/container/coder-xray)
4+
[![license](https://img.shields.io/github/license/coder/coder-xray)](./LICENSE)
5+
6+
Query JFrog Artifactory XRay scan results for Coder workspaces to a Coder deployment.
7+
8+
- Query Artifactory for image vulnerability on workspace startup.
9+
- Inform users when they are using a vulnerable image.
10+
11+
![Example](./scripts/example.png)
12+
13+
## Usage
14+
15+
Apply the Helm chart to start monitoring workspaces:
16+
17+
```console
18+
helm repo add coder-xray https://helm.coder.com/coder-xray
19+
--namespace coder \
20+
helm install coder-xray coder-xray/coder-xray \
21+
--set coder.url="https://<your-coder-url>" \
22+
--set coder.secretName="<your coder token secret>" \
23+
--set artifactory.url="https://<your-artifactory-url>" \
24+
--set artifactory.secretName="<your artifactory secret>"
25+
```
26+
27+
> **Note**
28+
> For additional customization (such as customizing the image, details on creating a secret, etc.), you can use the
29+
> [values.yaml](https://github.com/coder/coder-xray/blob/main/helm/values.yaml) file directly.
30+
31+
### Requirements:
32+
33+
In order to use this service the following is required:
34+
35+
- A Coder API token with _at least_ Template Admin privileges
36+
- An Artifactory token
37+
38+
## How?
39+
40+
Kubernetes provides an [informers](https://pkg.go.dev/k8s.io/client-go/informers) API that streams pod and event data from the API server.
41+
42+
`coder-xray` listens for pod creation events with containers that have the `CODER_AGENT_TOKEN` environment variable set. All matching pods/containers are then queried against the provided artifactory instance and any XRay results are then pushed to the provided Coder deployment.

0 commit comments

Comments
 (0)