Skip to content

Commit

Permalink
extend examples in docs
Browse files Browse the repository at this point in the history
  • Loading branch information
vbradnitski committed Nov 16, 2023
1 parent 5f67224 commit f2c395c
Show file tree
Hide file tree
Showing 3 changed files with 52 additions and 21 deletions.
39 changes: 39 additions & 0 deletions docs/usage.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -384,6 +384,45 @@ ingress.networking.k8s.io/my-domain-com created

Once the XP pods have started you can open up the admin by following the <<access-admin>> section or call the ingress controller, if you have one set up.

=== Simple shared volume example
In case you want to map all your disks to a single volume, you can change the `Xp7Deployment` resource to look like this:

.simple-shared-volume.yaml
[source,yaml]
----
# Create deployment in the namespace
apiVersion: enonic.cloud/v1
kind: Xp7Deployment
...
resources:
cpu: "1"
memory: 1Gi
dirs:
# Snapshotter app copied to deploy folder
- name: deploy
size: 100Mi
mountReadOnly: true
# Single inner volume for all disks
volumes:
- name: inner
size: 1Gi
# Private disks to use the shared private volume
disks:
- name: index
volume: inner
- name: work
volume: inner
- name: export
volume: inner
- name: snapshots
volume: inner
- name: blobstore
volume: inner
----

== Cluster example

WARNING: The values cpu and memory setting in this example are too low for a good cluster setup. They are set this way, so you can try it out on a low resource Kubernetes cluster.
Expand Down
32 changes: 12 additions & 20 deletions kubernetes/example-simple-shared.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,23 +17,6 @@ spec:
enabled: true
xpVersion: 7.13.4

nodesSharedVolumes:
- name: shared
size: 1Gi
class: nfs

# Create volumes shared by all nodes in this deployment
nodesSharedDisks:
- name: blobstore
volume: shared

- name: snapshots
volume: shared

- name: export # Dumps and other data
size: 1Gi
class: nfs

# Create one node
nodeGroups:
- name: main
Expand All @@ -50,17 +33,26 @@ spec:
cpu: "1"
memory: 1Gi
dirs:
# Snapshotter app copied to deploy folder
- name: deploy
size: 100Mi
mountReadOnly: true
# Single inner volume for all disks
volumes:
- name: inner
size: 1Gi

# Volumes private to the node
# Private disks to use the shared private volume
disks:
- name: index # Node ES index
- name: index
volume: inner
- name: work
volume: inner
- name: export
volume: inner
- name: snapshots
volume: inner
- name: work # Node cache
- name: blobstore
volume: inner
---
# Install content studio
Expand Down
2 changes: 1 addition & 1 deletion kubernetes/example-simple.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ spec:
- name: deploy
size: 100Mi
mountReadOnly: true
# Volumes private to the node
# Disks private to the node
disks:
- name: blobstore
size: 1Gi
Expand Down

0 comments on commit f2c395c

Please sign in to comment.