Aws Minikube
Aws Minikube
Aws Minikube
PROJECT2 LINK -
https://github.com/praveen1994dec/kubernetes_java_deploym
ent.git
yum update -y
DOCKER
MAVEN
cd /opt/
wget
http://mirrors.estointernet.in/apache/maven/maven-3/3.6.3/bin
aries/apache-maven-3.6.3-bin.tar.gz
tar xvzf apache-maven-3.6.3-bin.tar.gz
vi /etc/profile.d/maven.sh
export MAVEN_HOME=/opt/apache-maven-3.6.3
export PATH=$PATH:$MAVEN_HOME/bin
GIT
JAVA
curl -o kubectl
https://amazon-eks.s3.us-west-2.amazonaws.com/1.20.4/2021
-04-12/bin/linux/amd64/kubectl
chmod +x ./kubectl
mkdir -p $HOME/bin
cp ./kubectl $HOME/bin/kubectl
export PATH=$HOME/bin:$PATH
echo 'export PATH=$HOME/bin:$PATH' >> ~/.bashrc
source $HOME/.bashrc
kubectl version --short –client
STEP 4 –
[ 3 SERVICES IN PROJECT ]
cd shopfront/
mvn clean install -DskipTests
docker build -t praveensingam1994/shopfront:latest .
docker push praveensingam1994/shopfront:latest
cd productcatalogue/
mvn clean install -DskipTests
docker build -t praveensingam1994/productcatalogue:latest .
docker push praveensingam1994/productcatalogue:latest
cd stockmanager/
mvn clean install -DskipTests
docker build -t praveensingam1994/stockmanager:latest .
docker push praveensingam1994/stockmanager:latest
STEP 6 - GO TO KUBERNETES FOLDER IN SAME
PROJECT
cd kubernetes
/usr/local/bin/minikube dashboard
http://<EC2-IP>:8001/api/v1/namespaces/kubernetes-da
shboard/services/http:kubernetes-dashboard:/proxy/#/po
d?namespace=default
- http://<EC2IP>:8090/products
- [{"id":"1","name":"Widget","descriptio
n":"Premium ACME
Widgets","price":1.1999999999999999555
910790149937383830547332763671875},{"i
d":"2","name":"Sprocket","description"
:"Grade B
sprockets","price":4.09999999999999964
47286321199499070644378662109375},{"id
":"3","name":"Anvil","description":"La
rge
Anvils","price":45.5},{"id":"4","name"
:"Cogs","description":"Grade Y
cogs","price":1.8000000000000000444089
209850062616169452667236328125},{"id":
"5","name":"Multitool","description":"
Multitools","price":154.09999999999999
4315658113919198513031005859375}]
- http://<EC2IP>:9008/stocks
- [{"productId":"1","sku":"12345678","am
ountAvailable":5},{"productId":"2","sk
u":"34567890","amountAvailable":2},{"p
roductId":"3","sku":"54326745","amount
Available":999},{"productId":"4","sku"
:"93847614","amountAvailable":0},{"pro
ductId":"5","sku":"11856388","amountAv
ailable":1}]
STEP 12 – ANALYZE THE DASHBOARD