You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Step-04: Connect to RDS Database using kubectl and create usermgmt schema/db
# Template
kubectl run -it --rm --image=mysql:5.7.22 --restart=Never mysql-client -- mysql -h <AZURE-MYSQ-DB-HOSTNAME> -u <USER_NAME> -p<PASSWORD>
# Replace Host Name of Azure MySQL Database and Username and Password
kubectl run -it --rm --image=mysql:5.7.22 --restart=Never mysql-client -- mysql -h akswebappdb.mysql.database.azure.com -u dbadmin@akswebappdb -pRedhat1449
mysql> show schemas;
mysql> create database webappdb;
mysql> show schemas;
mysql> exit
Step-05: In User Management WebApp deployment file change username from root to dbadmin@akswebappdb
# Deploy all Manifests
kubectl apply -f kube-manifests/
# List Pods
kubectl get pods
# Stream pod logs to verify DB Connection is successful from SpringBoot Application
kubectl logs -f <pod-name>
Step-07: Access Application
# Get Public IP
kubectl get svc
# Access Application
http://<External-IP-from-get-service-output>
Username: admin101
Password: password101
Step-08: Clean Up
# Delete all Objects created
kubectl delete -f kube-manifests/
# Verify current Kubernetes Objects
kubectl get all
# Delete Azure MySQL Database