Skip to content

Commit 254ffc0

Browse files
authored
improve readme
1 parent 5d67edb commit 254ffc0

1 file changed

Lines changed: 23 additions & 21 deletions

File tree

README.md

Lines changed: 23 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,23 @@
22

33
# OpsLevel - Report Deploy Github Action
44

5-
This action emits a deploy event for service to OpsLevel.
5+
This action emits a deploy event for service to OpsLevel. We have configured it with sane defaults so you should only have to specify `integration_url` and `service`. `environment` defaults to `production` so if you want to track deploys from other environments you'll want to specific that too
6+
7+
## Example usage
8+
9+
```yaml
10+
jobs:
11+
deploy:
12+
steps:
13+
- name: Checkout
14+
uses: actions/checkout@v4
15+
- name: Report Deploy
16+
uses: OpsLevel/report-deploy-github-action@v2.0.0
17+
with:
18+
integration_url: ${{ secrets.DEPLOY_INTEGRATION_URL }}
19+
service: "my-service"
20+
use_docker: "true"
21+
```
622
723
## Inputs
824
@@ -18,19 +34,19 @@ If the repository has an `./opslevel.yml` file the service name will get pulled
1834

1935
### `description`
2036

21-
The description or release notes for the event - Default: ""
37+
The description or release notes for the event - Default: "Event Created by ${{ github.workflow }}"
2238

2339
### `environment`
2440

25-
The environment for the event - Default: ""
41+
The environment for the event - Default: "production"
2642

2743
### `number`
2844

29-
The deploy number for the event - Default: `${GITHUB_RUN_NUMBER}`
45+
The deploy number for the event - Default: `${{ github.run_number }}`
3046

3147
### `deployer_name`
3248

33-
The deployer name who created the event - Default: `${GITHUB_ACTOR}`
49+
The deployer name who created the event - Default: `${{ github.actor }}`
3450

3551
### `deployer_email`
3652

@@ -42,7 +58,7 @@ The deploy url that OpsLevel points to - Default: `${{ github.server_url }}/${{
4258

4359
### `deduplication_id`
4460

45-
An identifier that can be used to deduplicate deployments - Default: `${GITHUB_RUN_ID}`
61+
An identifier that can be used to deduplicate deployments - Default: `${{ github.run_id }}`
4662

4763
### `use_docker`
4864

@@ -56,21 +72,7 @@ While both behave identically, this action will run using Docker by default - se
5672
For Github workflows operating within intentional constraints, perhaps where building public Docker images is not
5773
an option, it may be preferable to use the OpsLevel CLI.
5874

59-
## Example usage
60-
61-
```yaml
62-
jobs:
63-
deploy:
64-
steps:
65-
- name: Checkout
66-
uses: actions/checkout@v4
67-
- name: Report Deploy
68-
uses: OpsLevel/report-deploy-github-action@v2.0.0
69-
with:
70-
integration_url: ${{ secrets.DEPLOY_INTEGRATION_URL }}
71-
service: "my-service"
72-
use_docker: "true"
73-
```
75+
## Overriding Defaults Example
7476

7577
If you want to add the git commit author as the deployer
7678

0 commit comments

Comments
 (0)