Skip to content

Commit 917723b

Browse files
authored
CLOUDP-346604: fixes for search snippets after 1.4.0 (#472)
# Summary This PR fixes search snippets issued found after the release 1.4.0 ## Proof of Work Passing search snippets tests: [evg link](https://spruce.mongodb.com/version/68d4f0827e318300077e3595/tasks?page=0&sorts=STATUS%3AASC%3BBASE_STATUS%3ADESC&variant=%5Eprivate_kind_code_snippets%24) ## Checklist - [ ] Have you linked a jira ticket and/or is the ticket in the title? - [ ] Have you checked whether your jira ticket required DOCSP changes? - [ ] Have you added changelog file? - use `skip-changelog` label if not needed - refer to [Changelog files and Release Notes](https://github.com/mongodb/mongodb-kubernetes/blob/master/CONTRIBUTING.md#changelog-files-and-release-notes) section in CONTRIBUTING.md for more details
1 parent de46cf9 commit 917723b

23 files changed

+37
-832
lines changed

docs/search/02-search-enterprise-deploy/code_snippets/02_0080_helm_login_to_prerelease_registry.sh

Lines changed: 0 additions & 8 deletions
This file was deleted.

docs/search/02-search-enterprise-deploy/code_snippets/02_0305_create_mongodb_database_resource.sh

Lines changed: 14 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ metadata:
55
name: ${MDB_RESOURCE_NAME}
66
spec:
77
members: 3
8-
version: ${MDB_VERSION}-ent
8+
version: ${MDB_VERSION}
99
type: ReplicaSet
1010
opsManager:
1111
configMapRef:
@@ -18,18 +18,17 @@ spec:
1818
modes:
1919
- SCRAM
2020
agent:
21-
logLevel: DEBUG
22-
statefulSet:
23-
spec:
24-
template:
25-
spec:
26-
containers:
27-
- name: mongodb-enterprise-database
28-
resources:
29-
limits:
30-
cpu: "2"
31-
memory: 2Gi
32-
requests:
33-
cpu: "1"
34-
memory: 1Gi
21+
logLevel: INFO
22+
podSpec:
23+
podTemplate:
24+
spec:
25+
containers:
26+
- name: mongodb-enterprise-database
27+
resources:
28+
limits:
29+
cpu: "2"
30+
memory: 2Gi
31+
requests:
32+
cpu: "1"
33+
memory: 1Gi
3534
EOF

docs/search/02-search-enterprise-deploy/code_snippets/02_0315_create_mongodb_users.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ EOF
2525
# For MongoDB <8.2, the operator will be creating the searchCoordinator custom role automatically
2626
# From MongoDB 8.2, searchCoordinator role will be a built-in role.
2727
kubectl --context "${K8S_CTX}" --namespace "${MDB_NS}" \
28-
create secret generic mdb-rs-search-sync-source-password \
28+
create secret generic "${MDB_RESOURCE_NAME}-search-sync-source-password" \
2929
--from-literal=password="${MDB_SEARCH_SYNC_USER_PASSWORD}"
3030
kubectl apply --context "${K8S_CTX}" -n "${MDB_NS}" -f - <<EOF
3131
apiVersion: mongodb.com/v1
@@ -38,7 +38,7 @@ spec:
3838
mongodbResourceRef:
3939
name: ${MDB_RESOURCE_NAME}
4040
passwordSecretKeyRef:
41-
name: mdb-rs-search-sync-source-password
41+
name: ${MDB_RESOURCE_NAME}-search-sync-source-password
4242
key: password
4343
roles:
4444
- name: searchCoordinator
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
echo "Waiting for MongoDBSearch resource to reach Running phase..."
2-
kubectl --context "${K8S_CTX}" -n "${MDB_NS}" wait --for=jsonpath='{.status.phase}'=Running mdbs/mdb-rs --timeout=300s
2+
kubectl --context "${K8S_CTX}" -n "${MDB_NS}" wait --for=jsonpath='{.status.phase}'=Running "mdbs/${MDB_RESOURCE_NAME}" --timeout=300s
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
echo; echo "MongoDB resource"
22
kubectl --context "${K8S_CTX}" -n "${MDB_NS}" get "mdb/${MDB_RESOURCE_NAME}"
33
echo; echo "MongoDBSearch resource"
4-
kubectl --context "${K8S_CTX}" -n "${MDB_NS}" get mdbs/mdb-rs
4+
kubectl --context "${K8S_CTX}" -n "${MDB_NS}" get "mdbs/${MDB_RESOURCE_NAME}"
55
echo; echo "Pods running in cluster ${K8S_CTX}"
66
kubectl --context "${K8S_CTX}" -n "${MDB_NS}" get pods

docs/search/02-search-enterprise-deploy/env_variables.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,13 @@ export OPS_MANAGER_PROJECT_NAME="<arbitrary project name>"
1414
export OPS_MANAGER_API_URL="https://cloud-qa.mongodb.com"
1515

1616
# The API key can be an Org Owner - the operator can create the project automatically then.
17-
# The API key can also be created in a particular project that was created manually with the Project Owner scope .
18-
export OPS_MANAGER_API_USER="abcdefg"
19-
export OPS_MANAGER_API_KEY="00000-abcd-efgh-1111-12345678"
20-
export OPS_MANAGER_ORG_ID="62a73abcdefgh12345678"
17+
# The API key can also be created in a particular project that was created manually with the Project Owner scope.
18+
export OPS_MANAGER_API_USER="<SET API USER>"
19+
export OPS_MANAGER_API_KEY="<SET API KEY>"
20+
export OPS_MANAGER_ORG_ID="<SET ORG ID>"
2121

2222
# minimum required MongoDB version for running MongoDB Search is 8.0.10
23-
export MDB_VERSION="8.0.10"
23+
export MDB_VERSION="8.0.14-ent"
2424

2525
# root admin user for convenience, not used here at all in this guide
2626
export MDB_ADMIN_USER_PASSWORD="admin-user-password-CHANGE-ME"
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,7 @@
11
export K8S_CTX="${CLUSTER_NAME}"
2+
3+
export OPS_MANAGER_PROJECT_NAME="${NAMESPACE}-${MDB_RESOURCE_NAME}"
4+
export OPS_MANAGER_API_URL="${OM_BASE_URL}"
5+
export OPS_MANAGER_API_USER="${OM_USER}"
6+
export OPS_MANAGER_API_KEY="${OM_API_KEY}"
7+
export OPS_MANAGER_ORG_ID="${OM_ORGID}"

docs/search/02-search-enterprise-deploy/env_variables_prerelease.sh

Lines changed: 0 additions & 25 deletions
This file was deleted.

docs/search/02-search-enterprise-deploy/output/02_0090_helm_add_mogodb_repo.out

Lines changed: 0 additions & 6 deletions
This file was deleted.

0 commit comments

Comments
 (0)