Skip to content
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
6 changes: 3 additions & 3 deletions cmd/scw/testdata/test-all-usage-cockpit-alert-usage.golden
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ USAGE:
scw cockpit alert <command>

AVAILABLE COMMANDS:
disable Disable managed alerts
enable Enable managed alerts
test Trigger a test alert
disable Disable the sending of managed alerts for the specified Project's Cockpit
enable Enable the sending of managed alerts for the specified Project's Cockpit
test Trigger a test alert to all of the Cockpit's receivers

FLAGS:
-h, --help help for alert
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ USAGE:
scw cockpit cockpit <command>

AVAILABLE COMMANDS:
activate Activate a Cockpit
deactivate Deactivate a Cockpit
get Get a Cockpit
reset-grafana Reset a Grafana
activate Activate the Cockpit of the specified Project ID
deactivate Deactivate the Cockpit of the specified Project ID
get Retrieve the Cockpit of the specified Project ID
reset-grafana Reset your Cockpit's Grafana associated with the specified Project ID

WORKFLOW COMMANDS:
wait Wait for a cockpit to reach a stable state (installation)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ USAGE:
scw cockpit contact <command>

AVAILABLE COMMANDS:
create Create a contact point
delete Delete an alert contact point
list List contact points
create Create a contact point to receive alerts for the default receiver
delete Delete a contact point for the default receiver
list Get a list of contact points for the Cockpit associated with the specified Project ID

FLAGS:
-h, --help help for contact
Expand Down
15 changes: 15 additions & 0 deletions cmd/scw/testdata/test-all-usage-cockpit-datasource-usage.golden
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
Datasource management commands.

USAGE:
scw cockpit datasource

FLAGS:
-h, --help help for datasource

GLOBAL FLAGS:
-c, --config string The path to the config file
-D, --debug Enable debug mode
-o, --output string Output format: json or human, see 'scw help output' for more info (default "human")
-p, --profile string The config profile to use
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ USAGE:
scw cockpit grafana-user <command>

AVAILABLE COMMANDS:
create Create a Grafana user
delete Delete a Grafana user
list List Grafana users
reset-password Reset a Grafana user's password
create Create a Grafana user for your Cockpit's Grafana instance. Make sure you save the automatically-generated password and the Grafana user ID
delete Delete a Grafana user from a Grafana instance, specified by the Cockpit's Project ID and the Grafana user ID
list Get a list of Grafana users who are able to connect to the Cockpit's Grafana instance
reset-password Reset a Grafana user's password specified by the Cockpit's Project ID and the Grafana user ID

FLAGS:
-h, --help help for grafana-user
Expand Down
4 changes: 2 additions & 2 deletions cmd/scw/testdata/test-all-usage-cockpit-plan-usage.golden
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ USAGE:
scw cockpit plan <command>

AVAILABLE COMMANDS:
list List pricing plans
select Select pricing plan
list Get a list of all pricing plans available
select Select your chosen pricing plan for your Cockpit, specifying the Cockpit's Project ID and the pricing plan's ID in the request

FLAGS:
-h, --help help for plan
Expand Down
8 changes: 4 additions & 4 deletions cmd/scw/testdata/test-all-usage-cockpit-token-usage.golden
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ USAGE:
scw cockpit token <command>

AVAILABLE COMMANDS:
create Create a token
delete Delete a token
get Get a token
list List tokens
create Create a token associated with the specified Project ID
delete Delete the token associated with the specified token ID
get Retrieve the token associated with the specified token ID
list Get a list of tokens associated with the specified Project ID

FLAGS:
-h, --help help for token
Expand Down
3 changes: 2 additions & 1 deletion cmd/scw/testdata/test-all-usage-cockpit-usage.golden
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
Cockpit's API allows you to activate your Cockpit on your Projects. Scaleway's Cockpit stores metrics and logs and provides a dedicated Grafana for dashboarding to visualize them.
Cockpit API.

USAGE:
scw cockpit <command>
Expand All @@ -9,6 +9,7 @@ AVAILABLE COMMANDS:
alert Managed alerts management commands
cockpit Cockpit management commands
contact Contacts management commands
datasource Datasource management commands
grafana-user Grafana user management commands
plan Pricing plans management commands
token Token management commands
Expand Down
97 changes: 56 additions & 41 deletions docs/commands/cockpit.md
Original file line number Diff line number Diff line change
@@ -1,42 +1,43 @@
<!-- DO NOT EDIT: this file is automatically generated using scw-doc-gen -->
# Documentation for `scw cockpit`
Cockpit's API allows you to activate your Cockpit on your Projects. Scaleway's Cockpit stores metrics and logs and provides a dedicated Grafana for dashboarding to visualize them.
Cockpit API.

- [Managed alerts management commands](#managed-alerts-management-commands)
- [Disable managed alerts](#disable-managed-alerts)
- [Enable managed alerts](#enable-managed-alerts)
- [Trigger a test alert](#trigger-a-test-alert)
- [Disable the sending of managed alerts for the specified Project's Cockpit](#disable-the-sending-of-managed-alerts-for-the-specified-project's-cockpit)
- [Enable the sending of managed alerts for the specified Project's Cockpit](#enable-the-sending-of-managed-alerts-for-the-specified-project's-cockpit)
- [Trigger a test alert to all of the Cockpit's receivers](#trigger-a-test-alert-to-all-of-the-cockpit's-receivers)
- [Cockpit management commands](#cockpit-management-commands)
- [Activate a Cockpit](#activate-a-cockpit)
- [Deactivate a Cockpit](#deactivate-a-cockpit)
- [Get a Cockpit](#get-a-cockpit)
- [Reset a Grafana](#reset-a-grafana)
- [Activate the Cockpit of the specified Project ID](#activate-the-cockpit-of-the-specified-project-id)
- [Deactivate the Cockpit of the specified Project ID](#deactivate-the-cockpit-of-the-specified-project-id)
- [Retrieve the Cockpit of the specified Project ID](#retrieve-the-cockpit-of-the-specified-project-id)
- [Reset your Cockpit's Grafana associated with the specified Project ID](#reset-your-cockpit's-grafana-associated-with-the-specified-project-id)
- [Wait for a cockpit to reach a stable state (installation)](#wait-for-a-cockpit-to-reach-a-stable-state-(installation))
- [Contacts management commands](#contacts-management-commands)
- [Create a contact point](#create-a-contact-point)
- [Delete an alert contact point](#delete-an-alert-contact-point)
- [List contact points](#list-contact-points)
- [Create a contact point to receive alerts for the default receiver](#create-a-contact-point-to-receive-alerts-for-the-default-receiver)
- [Delete a contact point for the default receiver](#delete-a-contact-point-for-the-default-receiver)
- [Get a list of contact points for the Cockpit associated with the specified Project ID](#get-a-list-of-contact-points-for-the-cockpit-associated-with-the-specified-project-id)
- [Datasource management commands](#datasource-management-commands)
- [Grafana user management commands](#grafana-user-management-commands)
- [Create a Grafana user](#create-a-grafana-user)
- [Delete a Grafana user](#delete-a-grafana-user)
- [List Grafana users](#list-grafana-users)
- [Reset a Grafana user's password](#reset-a-grafana-user's-password)
- [Create a Grafana user for your Cockpit's Grafana instance. Make sure you save the automatically-generated password and the Grafana user ID](#create-a-grafana-user-for-your-cockpit's-grafana-instance.-make-sure-you-save-the-automatically-generated-password-and-the-grafana-user-id)
- [Delete a Grafana user from a Grafana instance, specified by the Cockpit's Project ID and the Grafana user ID](#delete-a-grafana-user-from-a-grafana-instance,-specified-by-the-cockpit's-project-id-and-the-grafana-user-id)
- [Get a list of Grafana users who are able to connect to the Cockpit's Grafana instance](#get-a-list-of-grafana-users-who-are-able-to-connect-to-the-cockpit's-grafana-instance)
- [Reset a Grafana user's password specified by the Cockpit's Project ID and the Grafana user ID](#reset-a-grafana-user's-password-specified-by-the-cockpit's-project-id-and-the-grafana-user-id)
- [Pricing plans management commands](#pricing-plans-management-commands)
- [List pricing plans](#list-pricing-plans)
- [Select pricing plan](#select-pricing-plan)
- [Get a list of all pricing plans available](#get-a-list-of-all-pricing-plans-available)
- [Select your chosen pricing plan for your Cockpit, specifying the Cockpit's Project ID and the pricing plan's ID in the request](#select-your-chosen-pricing-plan-for-your-cockpit,-specifying-the-cockpit's-project-id-and-the-pricing-plan's-id-in-the-request)
- [Token management commands](#token-management-commands)
- [Create a token](#create-a-token)
- [Delete a token](#delete-a-token)
- [Get a token](#get-a-token)
- [List tokens](#list-tokens)
- [Create a token associated with the specified Project ID](#create-a-token-associated-with-the-specified-project-id)
- [Delete the token associated with the specified token ID](#delete-the-token-associated-with-the-specified-token-id)
- [Retrieve the token associated with the specified token ID](#retrieve-the-token-associated-with-the-specified-token-id)
- [Get a list of tokens associated with the specified Project ID](#get-a-list-of-tokens-associated-with-the-specified-project-id)


## Managed alerts management commands

Managed alerts management commands.


### Disable managed alerts
### Disable the sending of managed alerts for the specified Project's Cockpit

Disable the sending of managed alerts for the specified Project's Cockpit.

Expand All @@ -55,7 +56,7 @@ scw cockpit alert disable [arg=value ...]



### Enable managed alerts
### Enable the sending of managed alerts for the specified Project's Cockpit

Enable the sending of managed alerts for the specified Project's Cockpit.

Expand All @@ -74,7 +75,7 @@ scw cockpit alert enable [arg=value ...]



### Trigger a test alert
### Trigger a test alert to all of the Cockpit's receivers

Trigger a test alert to all of the Cockpit's receivers.

Expand All @@ -98,7 +99,7 @@ scw cockpit alert test [arg=value ...]
Cockpit management commands.


### Activate a Cockpit
### Activate the Cockpit of the specified Project ID

Activate the Cockpit of the specified Project ID.

Expand All @@ -117,7 +118,7 @@ scw cockpit cockpit activate [arg=value ...]



### Deactivate a Cockpit
### Deactivate the Cockpit of the specified Project ID

Deactivate the Cockpit of the specified Project ID.

Expand All @@ -136,7 +137,7 @@ scw cockpit cockpit deactivate [arg=value ...]



### Get a Cockpit
### Retrieve the Cockpit of the specified Project ID

Retrieve the Cockpit of the specified Project ID.

Expand All @@ -155,7 +156,7 @@ scw cockpit cockpit get [arg=value ...]



### Reset a Grafana
### Reset your Cockpit's Grafana associated with the specified Project ID

Reset your Cockpit's Grafana associated with the specified Project ID.

Expand Down Expand Up @@ -209,7 +210,7 @@ scw cockpit cockpit wait 11111111-1111-1111-1111-111111111111
Contacts management commands.


### Create a contact point
### Create a contact point to receive alerts for the default receiver

Create a contact point to receive alerts for the default receiver.

Expand All @@ -229,7 +230,7 @@ scw cockpit contact create [arg=value ...]



### Delete an alert contact point
### Delete a contact point for the default receiver

Delete a contact point for the default receiver.

Expand All @@ -249,7 +250,7 @@ scw cockpit contact delete [arg=value ...]



### List contact points
### Get a list of contact points for the Cockpit associated with the specified Project ID

Get a list of contact points for the Cockpit associated with the specified Project ID.

Expand All @@ -268,12 +269,26 @@ scw cockpit contact list [arg=value ...]



## Datasource management commands

Datasource management commands.

Datasource management commands.

**Usage:**

```
scw cockpit datasource
```



## Grafana user management commands

Grafana user management commands.


### Create a Grafana user
### Create a Grafana user for your Cockpit's Grafana instance. Make sure you save the automatically-generated password and the Grafana user ID

Create a Grafana user for your Cockpit's Grafana instance. Make sure you save the automatically-generated password and the Grafana user ID.

Expand All @@ -294,7 +309,7 @@ scw cockpit grafana-user create [arg=value ...]



### Delete a Grafana user
### Delete a Grafana user from a Grafana instance, specified by the Cockpit's Project ID and the Grafana user ID

Delete a Grafana user from a Grafana instance, specified by the Cockpit's Project ID and the Grafana user ID.

Expand All @@ -314,7 +329,7 @@ scw cockpit grafana-user delete [arg=value ...]



### List Grafana users
### Get a list of Grafana users who are able to connect to the Cockpit's Grafana instance

Get a list of Grafana users who are able to connect to the Cockpit's Grafana instance.

Expand All @@ -334,7 +349,7 @@ scw cockpit grafana-user list [arg=value ...]



### Reset a Grafana user's password
### Reset a Grafana user's password specified by the Cockpit's Project ID and the Grafana user ID

Reset a Grafana user's password specified by the Cockpit's Project ID and the Grafana user ID.

Expand All @@ -359,7 +374,7 @@ scw cockpit grafana-user reset-password [arg=value ...]
Pricing plans management commands.


### List pricing plans
### Get a list of all pricing plans available

Get a list of all pricing plans available.

Expand All @@ -378,7 +393,7 @@ scw cockpit plan list [arg=value ...]



### Select pricing plan
### Select your chosen pricing plan for your Cockpit, specifying the Cockpit's Project ID and the pricing plan's ID in the request

Select your chosen pricing plan for your Cockpit, specifying the Cockpit's Project ID and the pricing plan's ID in the request.

Expand All @@ -403,7 +418,7 @@ scw cockpit plan select [arg=value ...]
Token management commands.


### Create a token
### Create a token associated with the specified Project ID

Create a token associated with the specified Project ID.

Expand Down Expand Up @@ -432,7 +447,7 @@ scw cockpit token create [arg=value ...]



### Delete a token
### Delete the token associated with the specified token ID

Delete the token associated with the specified token ID.

Expand All @@ -451,7 +466,7 @@ scw cockpit token delete [arg=value ...]



### Get a token
### Retrieve the token associated with the specified token ID

Retrieve the token associated with the specified token ID.

Expand All @@ -470,7 +485,7 @@ scw cockpit token get <token-id ...> [arg=value ...]



### List tokens
### Get a list of tokens associated with the specified Project ID

Get a list of tokens associated with the specified Project ID.

Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ require (
github.com/moby/buildkit v0.11.6
github.com/opencontainers/go-digest v1.0.0
github.com/pkg/errors v0.9.1
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.21.0.20230915112452-d153ad293c76
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.21.0.20230918151823-4f048611ed7c
github.com/skratchdot/open-golang v0.0.0-20200116055534-eef842397966
github.com/spf13/cobra v1.7.0
github.com/spf13/pflag v1.0.5
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -491,8 +491,8 @@ github.com/rogpeppe/go-internal v1.10.0/go.mod h1:UQnix2H7Ngw/k4C5ijL5+65zddjncj
github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
github.com/sabhiram/go-gitignore v0.0.0-20210923224102-525f6e181f06 h1:OkMGxebDjyw0ULyrTYWeN0UNCCkmCWfjPnIA2W6oviI=
github.com/sabhiram/go-gitignore v0.0.0-20210923224102-525f6e181f06/go.mod h1:+ePHsJ1keEjQtpvf9HHw0f4ZeJ0TLRsxhunSI2hYJSs=
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.21.0.20230915112452-d153ad293c76 h1:HTPaL3E2wq++7XgM4u7Gq0QxWcUiq6I07Kir0hSKGWo=
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.21.0.20230915112452-d153ad293c76/go.mod h1:fCa7OJZ/9DRTnOKmxvT6pn+LPWUptQAmHF/SBJUGEcg=
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.21.0.20230918151823-4f048611ed7c h1:HM3dPr4NWDAAJDt3mmJGLZ+1SqvQNbRM0zBvBB4UHmU=
github.com/scaleway/scaleway-sdk-go v1.0.0-beta.21.0.20230918151823-4f048611ed7c/go.mod h1:fCa7OJZ/9DRTnOKmxvT6pn+LPWUptQAmHF/SBJUGEcg=
github.com/sclevine/spec v1.4.0 h1:z/Q9idDcay5m5irkZ28M7PtQM4aOISzOpj4bUPkDee8=
github.com/secure-systems-lab/go-securesystemslib v0.4.0 h1:b23VGrQhTA8cN2CbBw7/FulN9fTtqYUdS5+Oxzt+DUE=
github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo=
Expand Down
Loading