Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
jeyaramashok committed Mar 22, 2020
1 parent e398d05 commit db088b2
Show file tree
Hide file tree
Showing 5 changed files with 85 additions and 45 deletions.
65 changes: 32 additions & 33 deletions doc/cli/operator-sdk_new.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,48 +18,48 @@ operator-sdk new <project-name> [flags]

```
# Create a new project directory
$ mkdir $HOME/projects/example.com/
$ cd $HOME/projects/example.com/
$ mkdir $HOME/projects/example.com/
$ cd $HOME/projects/example.com/
# Go project
$ operator-sdk new app-operator
# Go project
$ operator-sdk new app-operator
# Ansible project
$ operator-sdk new app-operator --type=ansible \
--api-version=app.example.com/v1alpha1 \
--kind=AppService
# Ansible project
$ operator-sdk new app-operator --type=ansible \
--api-version=app.example.com/v1alpha1 \
--kind=AppService
# Helm project
$ operator-sdk new app-operator --type=helm \
--api-version=app.example.com/v1alpha1 \
--kind=AppService
# Helm project
$ operator-sdk new app-operator --type=helm \
--api-version=app.example.com/v1alpha1 \
--kind=AppService
$ operator-sdk new app-operator --type=helm \
--api-version=app.example.com/v1alpha1 \
--kind=AppService \
--helm-chart=myrepo/app
$ operator-sdk new app-operator --type=helm \
--api-version=app.example.com/v1alpha1 \
--kind=AppService \
--helm-chart=myrepo/app
$ operator-sdk new app-operator --type=helm \
--helm-chart=myrepo/app
$ operator-sdk new app-operator --type=helm \
--helm-chart=myrepo/app
$ operator-sdk new app-operator --type=helm \
--helm-chart=myrepo/app \
--helm-chart-version=1.2.3
$ operator-sdk new app-operator --type=helm \
--helm-chart=myrepo/app \
--helm-chart-version=1.2.3
$ operator-sdk new app-operator --type=helm \
--helm-chart=app \
--helm-chart-repo=https://charts.mycompany.com/
$ operator-sdk new app-operator --type=helm \
--helm-chart=app \
--helm-chart-repo=https://charts.mycompany.com/
$ operator-sdk new app-operator --type=helm \
--helm-chart=app \
--helm-chart-repo=https://charts.mycompany.com/ \
--helm-chart-version=1.2.3
$ operator-sdk new app-operator --type=helm \
--helm-chart=app \
--helm-chart-repo=https://charts.mycompany.com/ \
--helm-chart-version=1.2.3
$ operator-sdk new app-operator --type=helm \
--helm-chart=/path/to/local/chart-directories/app/
$ operator-sdk new app-operator --type=helm \
--helm-chart=/path/to/local/chart-directories/app/
$ operator-sdk new app-operator --type=helm \
--helm-chart=/path/to/local/chart-archives/app-1.2.3.tgz
$ operator-sdk new app-operator --type=helm \
--helm-chart=/path/to/local/chart-archives/app-1.2.3.tgz
```

Expand All @@ -84,4 +84,3 @@ operator-sdk new <project-name> [flags]
### SEE ALSO

* [operator-sdk](operator-sdk.md) - An SDK for building operators with ease

2 changes: 1 addition & 1 deletion website/content/en/docs/cli/operator-sdk_cleanup.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ operator-sdk cleanup [flags]
--kubeconfig string The file path to kubernetes configuration file. Defaults to location specified by $KUBECONFIG, or to default file rules if not set
--namespace string (Deprecated: use --operator-namespace instead.) The namespace from which operator and namespacesresources are cleaned up
--olm The operator to be cleaned up is managed by OLM in a cluster. Cannot be set with another cleanup-type flag (default true)
--olm-namespace string [olm only] The namespace where OLM is installed (default "olm")
--operator-namespace string [olm only] The namespace where operator resources are created in --olm mode. It must already exist in the cluster or be defined in a manifest passed to IncludePaths.
--manifests string [olm only] Directory containing package manifest and operator bundles.
--operator-version string [olm only] Version of operator to deploy
Expand All @@ -28,4 +29,3 @@ operator-sdk cleanup [flags]
### SEE ALSO

* [operator-sdk](operator-sdk.md) - An SDK for building operators with ease

55 changes: 48 additions & 7 deletions website/content/en/docs/cli/operator-sdk_new.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,58 @@ generates a default directory layout based on the input <project-name>.

<project-name> is the project name of the new operator. (e.g app-operator)

For example:

$ mkdir $HOME/projects/example.com/
$ cd $HOME/projects/example.com/
$ operator-sdk new app-operator
generates a skeletal app-operator application in $HOME/projects/example.com/app-operator.
```
operator-sdk new <project-name> [flags]
```

### Examples

```
operator-sdk new <project-name> [flags]
# Create a new project directory
$ mkdir $HOME/projects/example.com/
$ cd $HOME/projects/example.com/
# Go project
$ operator-sdk new app-operator
# Ansible project
$ operator-sdk new app-operator --type=ansible \
--api-version=app.example.com/v1alpha1 \
--kind=AppService
# Helm project
$ operator-sdk new app-operator --type=helm \
--api-version=app.example.com/v1alpha1 \
--kind=AppService
$ operator-sdk new app-operator --type=helm \
--api-version=app.example.com/v1alpha1 \
--kind=AppService \
--helm-chart=myrepo/app
$ operator-sdk new app-operator --type=helm \
--helm-chart=myrepo/app
$ operator-sdk new app-operator --type=helm \
--helm-chart=myrepo/app \
--helm-chart-version=1.2.3
$ operator-sdk new app-operator --type=helm \
--helm-chart=app \
--helm-chart-repo=https://charts.mycompany.com/
$ operator-sdk new app-operator --type=helm \
--helm-chart=app \
--helm-chart-repo=https://charts.mycompany.com/ \
--helm-chart-version=1.2.3
$ operator-sdk new app-operator --type=helm \
--helm-chart=/path/to/local/chart-directories/app/
$ operator-sdk new app-operator --type=helm \
--helm-chart=/path/to/local/chart-archives/app-1.2.3.tgz
```

### Options
Expand All @@ -42,4 +84,3 @@ operator-sdk new <project-name> [flags]
### SEE ALSO

* [operator-sdk](operator-sdk.md) - An SDK for building operators with ease

6 changes: 3 additions & 3 deletions website/content/en/docs/cli/operator-sdk_olm_status.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ operator-sdk olm status [flags]
### Options

```
-h, --help help for status
--timeout duration time to wait for the command to complete before failing (default 2m0s)
-h, --help help for status
--olm-namespace string namespace where OLM is installed (default "olm")
--timeout duration time to wait for the command to complete before failing (default 2m0s)
```

### SEE ALSO

* [operator-sdk olm](operator-sdk_olm.md) - Manage the Operator Lifecycle Manager installation in your cluster

2 changes: 1 addition & 1 deletion website/content/en/docs/cli/operator-sdk_run.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ operator-sdk run [flags]
--kubeconfig string The file path to kubernetes configuration file. Defaults to location specified by $KUBECONFIG, or to default file rules if not set
--namespace string (Deprecated: use --watch-namespace instead.)The namespace where the operator watches for changes.
--olm The operator to be run will be managed by OLM in a cluster. Cannot be set with another run-type flag
--olm-namespace string [olm only] The namespace where OLM is installed (default "olm")
--operator-namespace string [olm only] The namespace where operator resources are created in --olm mode. It must already exist in the cluster or be defined in a manifest passed to IncludePaths.
--manifests string [olm only] Directory containing package manifest and operator bundles.
--operator-version string [olm only] Version of operator to deploy
Expand All @@ -33,4 +34,3 @@ operator-sdk run [flags]
### SEE ALSO

* [operator-sdk](operator-sdk.md) - An SDK for building operators with ease

0 comments on commit db088b2

Please sign in to comment.