-
Notifications
You must be signed in to change notification settings - Fork 521
(DOCSP-11424): Document SCRAM Auth #196
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
melissamahoney-mongodb
merged 7 commits into
mongodb:master
from
melissamahoney-mongodb:DOCSP-11424
Sep 17, 2020
Merged
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
49f88f8
(DOCSP-11424): Document SCRAM Auth
melissamahoney-mongodb 19bad35
cleanup
melissamahoney-mongodb 69ebc2a
rearrange
melissamahoney-mongodb 0e3238c
more cleanup
melissamahoney-mongodb 0f0213a
copy review
melissamahoney-mongodb 67c66e1
tech review
melissamahoney-mongodb b4f5f4b
tech review 2
melissamahoney-mongodb File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Binary file not shown.
This file contains hidden or 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
Binary file not shown.
This file contains hidden or 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,10 @@ | ||
| # MongoDB Community Kubernetes Operator Documentation # | ||
|
|
||
| ## Table of Contents | ||
|
|
||
| - [Contribute to the MongoDB Kubernetes Operator](/docs/contributing.md) | ||
| - [MongoDB Community Kubernetes Operator Architecture](/docs/architecutre.md) | ||
| - [Install and Upgrade the Community Kubernetes Operator](/docs/install-upgrade.md) | ||
| - [Deploy and Configure MongoDB Resources](/docs/deploy-configure.md) | ||
| - [Create Database Users](/docs/users.md) | ||
| - [Secure MongoDB Resources](/docs/secure.md) |
File renamed without changes.
File renamed without changes.
This file contains hidden or 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,85 @@ | ||
| # Deploy and Configure a MongoDB Resource # | ||
|
|
||
| The [`/deploy/crds`](deploy/crds) directory contains example MongoDB resources that you can modify and deploy. | ||
|
|
||
| ## Table of Contents | ||
|
|
||
| - [Deploy a Replica Set](#deploy-a-replica-set) | ||
| - [Upgrade MongoDB Version & FCV](#upgrade-your-mongodb-resource-version-and-feature-compatibility-version) | ||
| - [Deploying on Openshift](#deploying-on-openshift) | ||
|
|
||
| ## Deploy a Replica Set | ||
|
|
||
| To deploy your first replica set: | ||
|
|
||
| 1. Invoke the following `kubectl` command: | ||
| ``` | ||
| kubectl apply -f deploy/crds/mongodb.com_v1_mongodb_cr.yaml --namespace <my-namespace> | ||
| ``` | ||
| 2. Verify that the MongoDB resource deployed: | ||
| ``` | ||
| kubectl get mongodb --namespace <my-namespace> | ||
| ``` | ||
| 3. Connect clients to the MongoDB replica set: | ||
| ``` | ||
| mongodb://<metadata.name of the MongoDB resource>-svc.<namespace>.svc.cluster.local:27017/?replicaSet=<replica set name> | ||
| ``` | ||
|
|
||
| ## Upgrade your MongoDB Resource Version and Feature Compatibility Version | ||
|
|
||
| You can upgrade the major, minor, and/or feature compatibility versions of your MongoDB resource. These settings are configured in your resource definition YAML file. | ||
|
|
||
| - To upgrade your resource's major and/or minor versions, set the `spec.version` setting to the desired MongoDB version. | ||
|
|
||
| - To modify your resource's [feature compatibility version](https://docs.mongodb.com/manual/reference/command/setFeatureCompatibilityVersion/), set the `spec.featureCompatibilityVersion` setting to the desired version. | ||
|
|
||
| If you update `spec.version` to a later version, consider setting `spec.featureCompatibilityVersion` to the current working MongoDB version to give yourself the option to downgrade if necessary. To learn more about feature compatibility, see [`setFeatureCompatibilityVersion`](https://docs.mongodb.com/manual/reference/command/setFeatureCompatibilityVersion/) in the MongoDB Manual. | ||
|
|
||
| ## Deploying on OpenShift | ||
|
|
||
| If you want to deploy the operator on OpenShift you will have to provide the environment variable `MANAGED_SECURITY_CONTEXT` set to `true` for both the mongodb and mongodb agent containers, as well as the operator deployment. | ||
|
|
||
| See [here](deploy/crds/mongodb.com_v1_mongodb_openshift_cr.yaml) for an example of how to provide the required configuration for a MongoDB ReplicaSet. | ||
|
|
||
| See [here](deploy/operator_openshift.yaml) for an example of how to configure the Operator deployment. | ||
|
|
||
| ### Example | ||
|
|
||
| Consider the following example MongoDB resource definition: | ||
|
|
||
| ```yaml | ||
| apiVersion: mongodb.com/v1 | ||
| kind: MongoDB | ||
| metadata: | ||
| name: example-mongodb | ||
| spec: | ||
| members: 3 | ||
| type: ReplicaSet | ||
| version: "4.0.6" | ||
| ``` | ||
| To upgrade this resource from `4.0.6` to `4.2.7`: | ||
|
|
||
| 1. Edit the resource definition. | ||
|
|
||
| a. Update `spec.version` to `4.2.7`. | ||
|
|
||
| b. Update `spec.featureCompatibilityVersion` to `4.0`. | ||
|
|
||
| ```yaml | ||
| apiVersion: mongodb.com/v1 | ||
| kind: MongoDB | ||
| metadata: | ||
| name: example-mongodb | ||
| spec: | ||
| members: 3 | ||
| type: ReplicaSet | ||
| version: "4.2.7" | ||
| featureCompatibilityVersion: "4.0" | ||
| ``` | ||
|
|
||
| **NOTE:** Setting `featureCompatibilityVersion` to `4.0` disables [4.2 features incompatible with MongoDB 4.0](https://docs.mongodb.com/manual/release-notes/4.2-compatibility/#compatibility-enabled). | ||
|
|
||
| 2. Reapply the configuration to Kubernetes: | ||
| ``` | ||
| kubectl apply -f <example>.yaml --namespace <my-namespace> | ||
| ``` | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consider adding a readme.md in /docs with a TOC to make it easier to find information instead of clicking the individual files.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
DIdn't realize I could have multiple readmes, good idea. Added.