Skip to content

Commit

Permalink
doc: add documentation #69
Browse files Browse the repository at this point in the history
  • Loading branch information
SLedunois committed Dec 30, 2022
1 parent c436e2c commit 350ffb0
Show file tree
Hide file tree
Showing 20 changed files with 487 additions and 2 deletions.
4 changes: 4 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ SHELL := /bin/bash
help:
@grep -E '[a-zA-Z\.\-]+:.*?@ .*$$' $(MAKEFILE_LIST)| tr -d '#' | awk 'BEGIN {FS = ":.*?@ "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'

#doc: @ generate command documentation
doc:
@go run cmd/doc/main.go

#test.unit: @ run unit tests and coverage
test.unit:
@echo "[TEST.UNIT] run unit tests and coverage"
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ Flags:
Use "bbsctl [command] --help" for more information about a command.
```

See the [documentation](docs/bbsctl.md) for more details.

### Init configuration
Use `b3lbctl init config` to initialize `b3lbctl` configuration.
```bash
Expand Down
14 changes: 14 additions & 0 deletions cmd/doc/main.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
// Binary bbsctl is a command line interface to manage BigBlueSwarm load balancer
package main

import (
"github.com/bigblueswarm/bbsctl/pkg/cmd/root"
"github.com/spf13/cobra/doc"
)

func main() {
cmd := root.NewCmd()
if err := doc.GenMarkdownTree(cmd, "./docs"); err != nil {
panic(err)
}
}
29 changes: 29 additions & 0 deletions docs/bbsctl.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
## bbsctl

BigBlueSwarm controller cli

### Synopsis

Manage your BigBlueSwarm cluster from the command line

```
bbsctl <command> [flags]
```

### Options

```
--config string config file (default is $HOME/.bigblueswarm/.bbsctl.yml) (default "$HOME/.bigblueswarm/.bbsctl.yml")
-h, --help help for bbsctl
```

### SEE ALSO

* [bbsctl apply](bbsctl_apply.md) - Apply a configuration to bigblueswarm server using a file
* [bbsctl cluster-info](bbsctl_cluster-info.md) - Get overall cluster information
* [bbsctl delete](bbsctl_delete.md) - Delete a specific resource
* [bbsctl describe](bbsctl_describe.md) - Show details of a specific resource or group of resources
* [bbsctl get](bbsctl_get.md) - Display a resource
* [bbsctl init](bbsctl_init.md) - Initialize a resource

###### Auto generated by spf13/cobra on 30-Dec-2022
30 changes: 30 additions & 0 deletions docs/bbsctl_apply.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
## bbsctl apply

Apply a configuration to bigblueswarm server using a file

### Synopsis

Apply a configuration to bigblueswarm server using a file

```
bbsctl apply -f [filepath] [flags]
```

### Options

```
-f, --file string resource file path
-h, --help help for apply
```

### Options inherited from parent commands

```
--config string config file (default is $HOME/.bigblueswarm/.bbsctl.yml) (default "$HOME/.bigblueswarm/.bbsctl.yml")
```

### SEE ALSO

* [bbsctl](bbsctl.md) - BigBlueSwarm controller cli

###### Auto generated by spf13/cobra on 30-Dec-2022
29 changes: 29 additions & 0 deletions docs/bbsctl_cluster-info.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
## bbsctl cluster-info

Get overall cluster information

### Synopsis

Get overall cluster information. It display all instances with %CPU, %MEM, Active meetings, Active paricipants and API status

```
bbsctl cluster-info [flags]
```

### Options

```
-h, --help help for cluster-info
```

### Options inherited from parent commands

```
--config string config file (default is $HOME/.bigblueswarm/.bbsctl.yml) (default "$HOME/.bigblueswarm/.bbsctl.yml")
```

### SEE ALSO

* [bbsctl](bbsctl.md) - BigBlueSwarm controller cli

###### Auto generated by spf13/cobra on 30-Dec-2022
30 changes: 30 additions & 0 deletions docs/bbsctl_delete.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
## bbsctl delete

Delete a specific resource

### Synopsis

Delete a specific resource

```
bbsctl delete <command> [flags]
```

### Options

```
-h, --help help for delete
```

### Options inherited from parent commands

```
--config string config file (default is $HOME/.bigblueswarm/.bbsctl.yml) (default "$HOME/.bigblueswarm/.bbsctl.yml")
```

### SEE ALSO

* [bbsctl](bbsctl.md) - BigBlueSwarm controller cli
* [bbsctl delete tenant](bbsctl_delete_tenant.md) - delete a tenant based on hostname

###### Auto generated by spf13/cobra on 30-Dec-2022
29 changes: 29 additions & 0 deletions docs/bbsctl_delete_tenant.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
## bbsctl delete tenant

delete a tenant based on hostname

### Synopsis

delete a tenant based on hostname

```
bbsctl delete tenant <hostname> [flags]
```

### Options

```
-h, --help help for tenant
```

### Options inherited from parent commands

```
--config string config file (default is $HOME/.bigblueswarm/.bbsctl.yml) (default "$HOME/.bigblueswarm/.bbsctl.yml")
```

### SEE ALSO

* [bbsctl delete](bbsctl_delete.md) - Delete a specific resource

###### Auto generated by spf13/cobra on 30-Dec-2022
31 changes: 31 additions & 0 deletions docs/bbsctl_describe.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
## bbsctl describe

Show details of a specific resource or group of resources

### Synopsis

Show details of a specific resource or group of resources

```
bbsctl describe <command> [flags]
```

### Options

```
-h, --help help for describe
```

### Options inherited from parent commands

```
--config string config file (default is $HOME/.bigblueswarm/.bbsctl.yml) (default "$HOME/.bigblueswarm/.bbsctl.yml")
```

### SEE ALSO

* [bbsctl](bbsctl.md) - BigBlueSwarm controller cli
* [bbsctl describe config](bbsctl_describe_config.md) - describe BigBlueSwarm configuration.
* [bbsctl describe tenant](bbsctl_describe_tenant.md) - Describe B3L tenant.

###### Auto generated by spf13/cobra on 30-Dec-2022
29 changes: 29 additions & 0 deletions docs/bbsctl_describe_config.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
## bbsctl describe config

describe BigBlueSwarm configuration.

### Synopsis

describe BigBlueSwarm configuration.

```
bbsctl describe config [flags]
```

### Options

```
-h, --help help for config
```

### Options inherited from parent commands

```
--config string config file (default is $HOME/.bigblueswarm/.bbsctl.yml) (default "$HOME/.bigblueswarm/.bbsctl.yml")
```

### SEE ALSO

* [bbsctl describe](bbsctl_describe.md) - Show details of a specific resource or group of resources

###### Auto generated by spf13/cobra on 30-Dec-2022
29 changes: 29 additions & 0 deletions docs/bbsctl_describe_tenant.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
## bbsctl describe tenant

Describe B3L tenant.

### Synopsis

Describe a given BigBlueSwarm tenant.

```
bbsctl describe tenant <hostname> [flags]
```

### Options

```
-h, --help help for tenant
```

### Options inherited from parent commands

```
--config string config file (default is $HOME/.bigblueswarm/.bbsctl.yml) (default "$HOME/.bigblueswarm/.bbsctl.yml")
```

### SEE ALSO

* [bbsctl describe](bbsctl_describe.md) - Show details of a specific resource or group of resources

###### Auto generated by spf13/cobra on 30-Dec-2022
31 changes: 31 additions & 0 deletions docs/bbsctl_get.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
## bbsctl get

Display a resource

### Synopsis

Display a resource

```
bbsctl get <command> [flags]
```

### Options

```
-h, --help help for get
```

### Options inherited from parent commands

```
--config string config file (default is $HOME/.bigblueswarm/.bbsctl.yml) (default "$HOME/.bigblueswarm/.bbsctl.yml")
```

### SEE ALSO

* [bbsctl](bbsctl.md) - BigBlueSwarm controller cli
* [bbsctl get instances](bbsctl_get_instances.md) - Display all BigBlueButton instances available in your BigBlueSwarm cluster
* [bbsctl get tenants](bbsctl_get_tenants.md) - Display all BigBlueSwarm tenants available in your BigBlueSwarm cluster

###### Auto generated by spf13/cobra on 30-Dec-2022
31 changes: 31 additions & 0 deletions docs/bbsctl_get_instances.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
## bbsctl get instances

Display all BigBlueButton instances available in your BigBlueSwarm cluster

### Synopsis

Display all BigBlueButton instances available in your BigBlueSwarm cluster

```
bbsctl get instances [flags]
```

### Options

```
-c, --csv csv output
-h, --help help for instances
-j, --json json output
```

### Options inherited from parent commands

```
--config string config file (default is $HOME/.bigblueswarm/.bbsctl.yml) (default "$HOME/.bigblueswarm/.bbsctl.yml")
```

### SEE ALSO

* [bbsctl get](bbsctl_get.md) - Display a resource

###### Auto generated by spf13/cobra on 30-Dec-2022
31 changes: 31 additions & 0 deletions docs/bbsctl_get_tenants.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
## bbsctl get tenants

Display all BigBlueSwarm tenants available in your BigBlueSwarm cluster

### Synopsis

Display all BigBlueSwarm tenants available in your BigBlueSwarm cluster

```
bbsctl get tenants [flags]
```

### Options

```
-c, --csv csv output
-h, --help help for tenants
-j, --json json output
```

### Options inherited from parent commands

```
--config string config file (default is $HOME/.bigblueswarm/.bbsctl.yml) (default "$HOME/.bigblueswarm/.bbsctl.yml")
```

### SEE ALSO

* [bbsctl get](bbsctl_get.md) - Display a resource

###### Auto generated by spf13/cobra on 30-Dec-2022
Loading

0 comments on commit 350ffb0

Please sign in to comment.