|
18 | 18 | - [deb, rpm and apk packages](#deb-rpm-and-apk-packages)
|
19 | 19 | - [go install](#go-install)
|
20 | 20 | - [Usage](#usage)
|
| 21 | + - [Webhook Server](#webhook-server) |
21 | 22 | - [GitLab-CI pipeline](#gitlab-ci-pipeline)
|
22 | 23 | - [Commands](#commands)
|
23 | 24 | - [`evaluate`](#evaluate)
|
@@ -113,9 +114,35 @@ go install github.com/jippi/scm-engine/cmd@latest
|
113 | 114 |
|
114 | 115 | ## Usage
|
115 | 116 |
|
| 117 | +### Webhook Server |
| 118 | + |
| 119 | +Using `scm-engine` as a webhook server allows for richer feature set compared to [GitLab CI pipeline](#gitlab-ci-pipeline) mode |
| 120 | + |
| 121 | +- `+` Reacting to comments |
| 122 | +- `+` Access to webhook event data in scripts via `webhook_event.*` (see [server docs](#server) for more information) |
| 123 | +- `+` A single `scm-engine` instance (and single token) for your GitLab project, group, or instance depending on where you configure the webhook. |
| 124 | +- `+` Each Project still have their own `.scm-engine.yml` file, it's downloaded via the API when the server is processing a webhook event. |
| 125 | +- `+` A single "bot" identity across your projects. |
| 126 | +- `+` Turn key once configured; if a project want to use `scm-engine` they just need to create the `.scm-engine.yml` file in their project. |
| 127 | +- `+` Real-time reactions to changes |
| 128 | +- `-` No intuitive access to [`evaluation` logs](#evaluate) within GitLab (you can see them in the server logs or in the webhook failure log) |
| 129 | + |
| 130 | +**Setup**: |
| 131 | + |
| 132 | +1. Deploy `scm-engine` within your infrastructure in an environment that can communicate egress/ingress with GitLab. ([see `server`](#server)) |
| 133 | +1. Configure your `webhook` at Project, Group, or Server level to hit the `/gitlab` endpoint on the `scm-engine` server endpoint. ([see `server`](#server)) |
| 134 | + |
116 | 135 | ### GitLab-CI pipeline
|
117 | 136 |
|
118 |
| -Using scm-engine within a GitLab CI pipeline is straight forward. |
| 137 | +Using `scm-engine` within a GitLab CI pipeline is straight forward - every time a CI pipeline runs, `scm-engine` will [evaluate](#evaluate) the Merge Request. |
| 138 | + |
| 139 | +- `+` Simple & quick installation. |
| 140 | +- `+` Limited access token permissions. |
| 141 | +- `+` Easy access to [`evaluation` logs](#evaluate) within the GitLab CI job. |
| 142 | +- `-` Can't react to comments; only works within a CI pipeline. |
| 143 | +- `-` Higher latency for reacting to changes depending on how fast CI jobs run (and where in the pipeline it runs). |
| 144 | + |
| 145 | +**Setup**: |
119 | 146 |
|
120 | 147 | 1. Add a `.scm-engine.yml` file in the root of your project.
|
121 | 148 | 1. Create a [CI/CD Variable](https://docs.gitlab.com/ee/ci/variables/#for-a-group)
|
|
0 commit comments