Skip to content

Commit

Permalink
Update Documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
Rizal Widyarta Gowandy committed Aug 30, 2021
1 parent d19b2e2 commit 86c91e3
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 8 deletions.
1 change: 1 addition & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# These are supported funding model platforms

patreon: rizalgowandy
ko_fi: rizalgowandy
Binary file added .github/terraform-rizalgowandy-newrelic.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
27 changes: 19 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,15 @@
# terraform-rizalgowandy-newrelic
[![Release](https://img.shields.io/github/release/rizalgowandy/terraform-rizalgowandy-newrelic.svg?style=flat-square)](https://github.com/rizalgowandy/terraform-rizalgowandy-newrelic/releases)

Terraform module to interact with NewRelic.
![terraform-rizalgowandy-newrelic](https://socialify.git.ci/rizalgowandy/terraform-rizalgowandy-newrelic/image?description=1&font=Inter&logo=https%3A%2F%2Fcdn.freebiesupply.com%2Flogos%2Flarge%2F2x%2Fnew-relic-logo-png-transparent.png&pattern=Circuit%20Board&theme=Light)

### Getting Started
## Getting Started

```hcl
The idea was simple, I want to have a standardized dashboard monitoring, and alert across all services across all environments.
In order that, some automation is required.

## Quick Start

```terraform
data "newrelic_entity" "app_grpc" {
# Replace with your service name.
name = "app_grpc"
Expand All @@ -22,12 +27,14 @@ module "grpc_dashboard" {
source = "git::https://github.com/rizalgowandy/terraform-rizalgowandy-newrelic?ref=v0.1.0"
# Replace with your account id.
account_id = var.account_id
account_id = var.account_id
# Replace with your application id.
application_id = data.newrelic_entity.app_grpc.application_id
# Replace with your policy id.
policy_id = newrelic_alert_policy.golden_signal_policy.id
# Set true to enable alert.
enable_alert = false
Expand All @@ -36,21 +43,25 @@ module "grpc_dashboard" {
service_name = "app_grpc"
# Replace with your metric name.
event_name = "grpc_performance"
event_name = "grpc_performance"
# Help make widget name more feasible with replacing long method name.
# Example:
# "/inventory.v1.Inventory/GetProducts" => "/v1.Inventory/GetProducts"
event_method_substring = "/inventory./"
event_method_replace = ""
# Replace with your metric method name.
event_methods = [
event_methods = [
"/inventory.v1.Inventory/GetProducts",
"/inventory.v1.Inventory/CheckStocks",
]
}
```

### Standardized Event Tags
## Standardized Event Tags

In order to have all the automation works correctly. You will need to push a specific tag for each event.

- metric_status => `ENUM('success', 'error', 'expected_error')`
- method => e.g `"/inventory.v1.Inventory/GetProducts"`
Expand Down

0 comments on commit 86c91e3

Please sign in to comment.