[go: nahoru, domu]

Skip to content

Commit

Permalink
Merge pull request #1 from shallada/master
Browse files Browse the repository at this point in the history
Modified the instructions dealing with creating secrets
  • Loading branch information
csplinter committed Jul 24, 2020
2 parents 775ba3b + a0d82f5 commit b658b55
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -105,15 +105,12 @@ kubectl -n cass-operator apply -f deploy/cassandra-4.0.0-1node.yml
Create the Kubernetes Secrets for database username and password
```
# get the username and password from the secret
kubectl -n cass-operator get secret cluster1-superuser -o yaml
# decode the username and password from the secret
echo <username> | base64 -D && echo ""
echo <password> | base64 -D && echo ""
DB_USER=$(kubectl -n cass-operator get secret cluster1-superuser -o yaml | grep username | cut -d " " -f 4 | base64 -d)
DB_PASSWORD=$(kubectl -n cass-operator get secret cluster1-superuser -o yaml | grep password | cut -d " " -f 4 | base64 -d)
# create k8s secrets for the services (skip cmd for Spring Boot service if using Astra)
kubectl -n spring-boot-service create secret generic db-secret --from-literal=username=<db-username> --from-literal=password=<db-password>
kubectl -n spring-data-service create secret generic db-secret --from-literal=username=<db-username> --from-literal=password=<db-password>
kubectl -n spring-boot-service create secret generic db-secret --from-literal=username=$DB_USER --from-literal=password=$DB_PASSWORD
kubectl -n spring-data-service create secret generic db-secret --from-literal=username=$DB_USER --from-literal=password=$DB_PASSWORD
```

### 3.d - (Optional) Use DataStax Astra for Spring Boot Service
Expand Down

0 comments on commit b658b55

Please sign in to comment.