Skip to content
Merged
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
21 changes: 15 additions & 6 deletions doc/milestone/user_guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -113,17 +113,18 @@ memcached-operator 1 1 1 1 1m

### Create a Memcached CR

Run the following command to create a `Memcached` custom resource:
Modify `deploy/cr.yaml` as shown and create a `Memcached` custom resource:

```sh
$ cat <<EOF | kubectl apply -f -
$ cat deploy/cr.yaml
apiVersion: "cache.example.com/v1alpha1"
kind: "Memcached"
metadata:
name: "example-memcached"
spec:
size: 3
EOF

$ kubectl apply -f deploy/cr.yaml
```

Ensure that the memcached-operator creates the deployment for the CR:
Expand Down Expand Up @@ -170,10 +171,18 @@ status:

### Update the size

Change the `spec.size` field in the memcached CR from 3 to 4:
Change the `spec.size` field in the memcached CR from 3 to 4 and apply the change:

```sh
$ kubectl get memcached/example-memcached -o yaml | sed 's|size: 3|size: 4|g' | kubectl apply -f -
$ cat deploy/cr.yaml
apiVersion: "cache.example.com/v1alpha1"
kind: "Memcached"
metadata:
name: "example-memcached"
spec:
size: 4

$ kubectl apply -f deploy/cr.yaml
```

Confirm that the operator changes the deployment size:
Expand All @@ -189,7 +198,7 @@ example-memcached 4 4 4 4 5m
Clean up the resources:

```sh
$ kubectl delete memcached example-memcached
$ kubectl delete -f deploy/cr.yaml
$ kubectl delete -f deploy/operator.yaml
```

Expand Down