-
Notifications
You must be signed in to change notification settings - Fork 114
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
move additional volume doc to examples
- Loading branch information
Showing
2 changed files
with
52 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
# Mounting Additional Volumes | ||
# | ||
# It is also possible to mount additional volumes to the SolrCloud (or its initContainers). Some example scenarios where you might use this would be: | ||
# - Custom solr plugins that rely on certain data to be present on disk | ||
# - Bootstrapping additional configuration for Solr via a ConfigMap | ||
# | ||
# Below is an example of the last scenario: | ||
|
||
apiVersion: solr.apache.org/v1beta1 | ||
kind: SolrCloud | ||
metadata: | ||
name: test | ||
namespace: test | ||
spec: | ||
replicas: 1 | ||
customSolrKubeOptions: | ||
podOptions: | ||
volumes: | ||
- source: | ||
configMap: | ||
name: configset | ||
defaultMode: 0777 | ||
name: configset | ||
defaultContainerMount: | ||
mountPath: /configset | ||
name: configset | ||
sidecarContainers: | ||
- name: config-loader | ||
image: alpine/curl:latest | ||
command: | ||
- "sh" | ||
- "-c" | ||
- "ls -la /configset" | ||
volumeMounts: | ||
- name: configset | ||
mountPath: /configset | ||
|
||
# Note the `source` spec may change based on the implementation. In this case, the `configMap` spec requires field `name`. | ||
# See volume spec in CRD: https://github.com/apache/solr-operator/blob/main/config/crd/bases/solr.apache.org_solrclouds.yaml#L6800 | ||
|
||
--- | ||
kind: ConfigMap | ||
apiVersion: v1 | ||
metadata: | ||
name: configset | ||
namespace: test | ||
data: | ||
config.xml: | | ||
<?xml version="1.0" encoding="UTF-8" ?> | ||
<config> | ||
... | ||
</config> |