You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: versioned_docs/version-4.0.0/ci-cd/github.md
+48Lines changed: 48 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -23,6 +23,8 @@ Keploy can be integrated with GitHub by two methods:-
23
23
1.[Using Shell Scripts](#shell-scripts)
24
24
2.[Using GitHub Actions](#github-actions)
25
25
26
+
If you run a self-hosted Keploy cluster, you can also [run Cloud Replay from CI](#cloud-replay-self-hosted-in-github-actions).
27
+
26
28
## Shell Scripts
27
29
28
30
GitHub scripts are the easiest way to integrate Keploy with GitHub. We will be using [express-mongoose](https://github.com/keploy/samples-typescript/tree/main/express-mongoose) sample-application for the example. You can either add the following script to yout `github workflow` or create a new worflow `.github/workflows/keploy-test.yml`:-
_And... voila! You have successfully integrated keploy in GitHub CI pipeline 🌟_
217
219
220
+
---
221
+
222
+
## Cloud Replay (Self-Hosted) in GitHub Actions
223
+
224
+
If you run a self-hosted Keploy cluster, you can replay your recorded test sets against the cluster directly from CI — with no browser login. CI authenticates using an **API key**, and the replay runs **inside your cluster**.
225
+
226
+
> Cloud Replay is an **Enterprise** feature and uses the Enterprise Keploy binary (installed in the workflow below), not the open-source binary.
227
+
228
+
```bash
229
+
export KEPLOY_API_KEY="<API_KEY>"
230
+
```
231
+
232
+
The Keploy CLI reads `KEPLOY_API_KEY` from the environment automatically, so no `keploy login` or browser step is needed in CI.
Replace `<NAMESPACE>`, `<DEPLOYMENT>`, and `<CLUSTER>` with your own values, and set `<DELAY>` to cover your application's startup time.
260
+
261
+
> - `--delay` is how long Keploy waits for the app to become ready before sending requests. If it is shorter than the app's cold-start time, the tests can all fail.
262
+
> - The CI runner must be able to reach your cluster's ingress URL.
263
+
264
+
The step passes when the replay summary reports `Failed 0`.
265
+
218
266
Hope this helps you out, if you still have any questions, reach out to us .
0 commit comments