Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(cockpit): add support for alerts #4106

Merged
merged 1 commit into from
Sep 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ USAGE:
ARGS:
[project-id] Project ID to use. If none is passed the default project ID will be used
[name] Data source name
[type] Data source type (unknown_type | metrics | logs | traces)
[type] Data source type (unknown_type | metrics | logs | traces | alerts)
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par | nl-ams | pl-waw)

FLAGS:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ ARGS:
[order-by] Sort order for data sources in the response (created_at_asc | created_at_desc | name_asc | name_desc | type_asc | type_desc)
[project-id] Project ID to use. If none is passed the default project ID will be used
[origin] Origin to filter for, only data sources with matching origin will be returned (unknown_origin | scaleway | external)
[types.{index}] Types to filter for, only data sources with matching types will be returned (unknown_type | metrics | logs | traces)
[types.{index}] Types to filter for, only data sources with matching types will be returned (unknown_type | metrics | logs | traces | alerts)
[region=fr-par] Region to target. If none is passed will use default region from the config (fr-par | nl-ams | pl-waw | all)

FLAGS:
Expand Down
4 changes: 2 additions & 2 deletions docs/commands/cockpit.md
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ scw cockpit data-source create [arg=value ...]
|------|---|-------------|
| project-id | | Project ID to use. If none is passed the default project ID will be used |
| name | | Data source name |
| type | One of: `unknown_type`, `metrics`, `logs`, `traces` | Data source type |
| type | One of: `unknown_type`, `metrics`, `logs`, `traces`, `alerts` | Data source type |
| region | Default: `fr-par`<br />One of: `fr-par`, `nl-ams`, `pl-waw` | Region to target. If none is passed will use default region from the config |


Expand Down Expand Up @@ -270,7 +270,7 @@ scw cockpit data-source list [arg=value ...]
| order-by | One of: `created_at_asc`, `created_at_desc`, `name_asc`, `name_desc`, `type_asc`, `type_desc` | Sort order for data sources in the response |
| project-id | | Project ID to use. If none is passed the default project ID will be used |
| origin | One of: `unknown_origin`, `scaleway`, `external` | Origin to filter for, only data sources with matching origin will be returned |
| types.{index} | One of: `unknown_type`, `metrics`, `logs`, `traces` | Types to filter for, only data sources with matching types will be returned |
| types.{index} | One of: `unknown_type`, `metrics`, `logs`, `traces`, `alerts` | Types to filter for, only data sources with matching types will be returned |
| region | Default: `fr-par`<br />One of: `fr-par`, `nl-ams`, `pl-waw`, `all` | Region to target. If none is passed will use default region from the config |


Expand Down
4 changes: 2 additions & 2 deletions internal/namespaces/cockpit/v1/cockpit_cli.go
Original file line number Diff line number Diff line change
Expand Up @@ -546,7 +546,7 @@ The name of the data source will then be used as reference to name the associate
Required: false,
Deprecated: false,
Positional: false,
EnumValues: []string{"unknown_type", "metrics", "logs", "traces"},
EnumValues: []string{"unknown_type", "metrics", "logs", "traces", "alerts"},
},
core.RegionArgSpec(scw.RegionFrPar, scw.RegionNlAms, scw.RegionPlWaw),
},
Expand Down Expand Up @@ -661,7 +661,7 @@ You can list data sources by Project, type and origin.`,
Required: false,
Deprecated: false,
Positional: false,
EnumValues: []string{"unknown_type", "metrics", "logs", "traces"},
EnumValues: []string{"unknown_type", "metrics", "logs", "traces", "alerts"},
},
core.RegionArgSpec(scw.RegionFrPar, scw.RegionNlAms, scw.RegionPlWaw, scw.Region(core.AllLocalities)),
},
Expand Down
Loading