Skip to content

Commit 708b2e2

Browse files
adding a warning in deploy-image plugin doc
1 parent 5c949c2 commit 708b2e2

File tree

1 file changed

+16
-2
lines changed

1 file changed

+16
-2
lines changed

docs/book/src/plugins/deploy-image-plugin-v1-alpha.md

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ The deploy-image plugin allows users to create [controllers][controller-runtime]
44
the guidelines and best practices. It abstracts the complexities to achieve this goal while allowing users to improve and customize their projects.
55

66
By using this plugin you will have:
7+
78
- a controller implementation to Deploy and manage an Operand(image) on the cluster
89
- tests to check the reconciliation implemented using [ENVTEST][envtest]
910
- the custom resources samples updated with the specs used
@@ -32,6 +33,19 @@ Then, by using this plugin you can [create APIs](https://book.kubebuilder.io/cro
3233
kubebuilder create api --group example.com --version v1alpha1 --kind Memcached --image=memcached:1.6.15-alpine --image-container-command="memcached,-m=64,modern,-v" --image-container-port="11211" --run-as-user="1001" --plugins="deploy-image/v1-alpha"
3334
```
3435

36+
<aside class="warning">
37+
<h1>Using make run</h1>
38+
39+
The `make run` will execute the `main.go` outside of the cluster to let you test the project running it locally. Note that by using this plugin the Operand image informed will be stored via an environment variable in the `config/manager/manager.yaml` manifest.
40+
41+
Therefore, before run `make run` you need to export any environment variable that you might have. Example:
42+
43+
```sh
44+
export MEMCACHED_IMAGE="memcached:1.4.36-alpine"
45+
```
46+
47+
</aside>
48+
3549
## Subcommands
3650

3751
The deploy-image plugin implements the following subcommands:
@@ -48,8 +62,8 @@ With the `create api` command of this plugin, in addition to the existing scaffo
4862
- `api/<version>/*_types.go` (scaffold the specs for the new api)
4963
- `config/samples/*_.yaml` (scaffold default values for its CR)
5064
- `main.go` (update to add controller setup)
51-
- `config/manager.yaml` (update with envvar to store the image)
65+
- `config/manager/manager.yaml` (update with envvar to store the image)
5266

5367
[controller-runtime]: https://github.com/kubernetes-sigs/controller-runtime
5468
[testdata]: https://github.com/kubernetes-sigs/kubebuilder/tree/master/testdata/
55-
[envtest]: ../reference/envtest.md
69+
[envtest]: ../reference/envtest.md

0 commit comments

Comments
 (0)