You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Oct 14, 2020. It is now read-only.
- Add a macosOS section with Homebrew.
- Linebreak long commands.
- Change the export: We can just use localhost.
- Add hint about direnv.
- Clarify instructions about uninstalling the operator.
Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Copy file name to clipboardExpand all lines: docs/developer-guide/README.md
+36-12Lines changed: 36 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,51 +14,75 @@ For local development we recommend to use [Minikube](https://kubernetes.io/docs/
14
14
15
15
#### Operating Your Local Kubernetes Cluster
16
16
17
-
To operate your (local) kubernetes cluster you will need to install [kubectl](https://kubernetes.io/docs/tasks/tools/install-kubectl/) and [helm](https://helm.sh/)
17
+
To operate your (local) Kubernetes cluster you will need to install [kubectl](https://kubernetes.io/docs/tasks/tools/install-kubectl/) and [helm](https://helm.sh/)
18
+
19
+
#### macOS
20
+
21
+
For macOs simply use [Homebrew](https://brew.sh/) to install all the tools:
22
+
23
+
```bash
24
+
brew cask install docker
25
+
brew install go helm
26
+
```
27
+
28
+
After that start the `Docker.app` and go to it's settings and start Kubernetes.
18
29
19
30
#### Minio
20
31
21
32
For your local development you will need a S3 compatible storage.
22
-
We would recommend to use [Minio](https://min.io/download#/) inside a podman or docker container.
33
+
We would recommend to use [Minio](https://min.io/download#/) inside a Podman or docker container.
23
34
24
35
##### If You Want to Use Podman
25
36
26
37
```bash
27
-
podman run --name minio -p 9000:9000 minio/minio server /data
38
+
podman run \
39
+
--name minio \
40
+
-p 9000:9000 \
41
+
minio/minio \
42
+
server /data
28
43
```
29
44
30
45
##### If You Want to Use Docker
31
46
32
47
```bash
33
-
docker run --name minio -p 9000:9000 minio/minio server /data
48
+
docker container run \
49
+
--name minio \
50
+
-p 9000:9000 \
51
+
-d \
52
+
--rm \
53
+
minio/minio \
54
+
server /data
34
55
```
35
56
36
-
In the Minio management GUI you will need to add a new bucket for the operator. The default credentials for your minio instance are `minioadmin:minioadmin`. You might change those.
37
-
38
-
After setting up your bucket you will need to specify some environment variables to enable the operator to use the bucket.
39
-
You could add these to your `.bashrc` or `.zshrc` as well.
57
+
In the Minio management GUI you will need to add a new bucket for the operator. The default credentials for your minio instance are `minioadmin:minioadmin`. You might change those. Go to the management UI at <http://localhost:9000/> and add a new bucket. After creating your bucket you will need to specify some environment variables to enable the operator to use the bucket. For that export these variables:
40
58
41
59
```bash
42
60
export S3_ACCESS_KEY="your-minio-access-key"
43
61
export S3_SECRET_KEY="your-minio-secret-key"
44
62
export S3_BUCKET="name-of-your-bucket"
45
63
export S3_USE_SSL="false"# This ensures that the operator will connect even without HTTPS
You can save time by using [direnv](https://direnv.net/) to export these variables in your project.
68
+
49
69
### Build and Run the Operator
50
70
51
-
To build an run the operator you can simply execute *make* in the *operator* directory of this repository.
71
+
To build an run the operator you can simply execute `make` in the `operator` directory of this repository:
52
72
53
73
```bash
74
+
cd operator
54
75
make
55
76
```
56
77
57
-
To run the operator locally you can simply execute *make run*
78
+
This will produce the operator as `bin/manager`. If you wonder why the operator is named _manager_ (the resulting binary). The reason for that is in Kubernetes a combination of more than one _controller_ is called _controller-manager_ or short _manager_. In contrast _operator_ is created by the community to name a _controller-manager_ which controls _custom resources_ and hence we use _custom resources_. (see <https://book.kubebuilder.io/> for further information)
79
+
80
+
To run the operator locally you can simply execute `make run` in the `operator` directory of this repository:
58
81
59
-
*NOTICE:* You will need to uninstall the operator from your local cluster first or it will result in undefined behavior!
82
+
*NOTICE:* You will need to uninstall the operator with `helm -n securecodebox-system uninstall securecodebox-operator`from your local cluster, if you've installed it via helm. Unless both operators try to work on the same cluster which may cause unexpected behavior.
0 commit comments