Skip to content

Commit

Permalink
fix?
Browse files Browse the repository at this point in the history
  • Loading branch information
tomklapiscak committed Apr 25, 2024
1 parent 261da7d commit a76e91f
Showing 1 changed file with 0 additions and 43 deletions.
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
{{- if not (empty .Values.docdb) }}
---



apiVersion: batch/v1
kind: Job
metadata:
Expand Down Expand Up @@ -108,46 +105,6 @@ spec:
echo "TODO: Run /opt/app-root/src/run-role.sh aws_documentdb_user (user action ${USER_ACTION})"
# Read the username/password generated by the role
# "{{ mas_config_dir }}/{{ docdb_instance_credentials_secret_name }}.yml"
{# apiVersion: v1
kind: Secret
type: Opaque
metadata:
name: "{{ docdb_instance_credentials_secret_name }}"
data:
docdb_username: "{{ docdb_instance_username | b64encode }}"
docdb_password: "{{ docdb_instance_password | b64encode }}" #}
# DOCDB_INSTANCE_USERNAME="masinst_${MAS_INSTANCE_ID}"
# DOCDB_INSTANCE_PASSWORD=${DOCDB_INSTANCE_PASSWORD:-`cat /dev/urandom | tr -dc 'a-zA-Z0-9' | head -c 20`}
echo
echo "================================================================================"
echo "Updating $SECRET_NAME_MONGO"
echo "================================================================================"
# echo "DOCDB_MASTER_INFO=${DOCDB_MASTER_INFO}"
# echo "DOCDB_INSTANCE_USERNAME=${DOCDB_INSTANCE_USERNAME:0:2}<snip>"
# echo "DOCDB_INSTANCE_PASSWORD=${DOCDB_INSTANCE_PASSWORD:0:2}<snip>"
# echo "SM_AWS_REGION=${SM_AWS_REGION}"
# echo "SM_AWS_ACCESS_KEY_ID=${SM_AWS_ACCESS_KEY_ID:0:2}<snip>"
# echo "SM_AWS_SECRET_ACCESS_KEY=${SM_AWS_SECRET_ACCESS_KEY:0:2}<snip>"
# echo "SECRET_NAME_MONGO=${SECRET_NAME_MONGO}"
# echo
# echo "DOCDB_MASTER_INFO_ESCAPED:"
# echo "${DOCDB_MASTER_INFO_ESCAPED}"
# DOCDB_MASTER_INFO_ESCAPED=${DOCDB_MASTER_INFO//\"/\\\"}
# DOCDB_MASTER_INFO_ESCAPED=${DOCDB_MASTER_INFO_ESCAPED//$'\n'/\\n}
# SECRETS_KEY_SEPERATOR="/"
# export SECRET_NAME_MONGO=${ACCOUNT_ID}${SECRETS_KEY_SEPERATOR}${CLUSTER_ID}${SECRETS_KEY_SEPERATOR}${MAS_INSTANCE_ID}${SECRETS_KEY_SEPERATOR}mongo
# source /mascli/functions/gitops_utils
# sm_login
# sm_update_secret $SECRET_NAME_MONGO "{\"info\":\"$DOCDB_MASTER_INFO_ESCAPED\", \"username\":\"$DOCDB_INSTANCE_USERNAME\", \"password\":\"$DOCDB_INSTANCE_PASSWORD\"}"
restartPolicy: Never
serviceAccountName: sync-sa
backoffLimit: 4
Expand Down

0 comments on commit a76e91f

Please sign in to comment.