Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
flowerinthenight committed Apr 26, 2024
1 parent ea127f7 commit 3ac5ad9
Showing 1 changed file with 23 additions and 6 deletions.
29 changes: 23 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,27 @@ When started, the resulting `kubectl` child process will use its current config

The provided [Dockerfile](./Dockerfile) is for reference only as it's not configured to access any cluster.

```sh
# Build:
$ docker build --rm -t oomkill-watch .

# Run using docker:
$ docker run -it --rm oomkill-watch
I have only tried deploying this tool to a GKE cluster. You might want to use other commands to configure `kubectl` inside the pod for proper cluster access. Here's a snippet of the deployment file I used:

```yaml
apiVersion: apps/v1
kind: Deployment
...
spec:
selector:
matchLabels:
app: oomkillwatchd
replicas: 1
revisionHistoryLimit: 5
template:
metadata:
labels:
app: oomkillwatchd
spec:
containers:
- name: oomkillwatchd
image: "your-image-here"
command: ["/bin/bash"]
args: ["-c", 'gcloud container clusters get-credentials {clustername} && /app/oomkill-watch -slack {channel}']
...
```

0 comments on commit 3ac5ad9

Please sign in to comment.