Skip to content
Permalink
Branch: master
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
34 lines (26 sloc) 1.16 KB
#!/bin/bash
#
# author: Gary A. Stafford
# site: https://programmaticponderings.com
# license: MIT License
# purpose: Optional: Deploy Kubernetes/Istio resources
# Constants - CHANGE ME!
readonly NAMESPACES=(dev test)
readonly SERVICES=(a b c d e f g h)
# Create Namespaces
kubectl apply -f ./resources/other/namespaces.yaml
kubectl apply -f ./resources/other/istio-gateway.yaml
kubectl apply -f ../golang-srv-demo-secrets/other/external-mesh-mongodb-atlas.yaml
kubectl apply -f ../golang-srv-demo-secrets/other/external-mesh-cloudamqp.yaml
for namespace in ${NAMESPACES[@]}; do
# Enable automatic Istio sidecar injection
kubectl label namespace ${namespace} istio-injection=enabled
# kubectl apply -n $namespace -f ./resources/configs/go-srv-demo.yaml
# kubectl apply -n $namespace -f ./resources/services/rabbitmq.yaml
# kubectl apply -n $namespace -f ./resources/services/mongodb.yaml
kubectl apply -n ${namespace} -f ../golang-srv-demo-secrets/secret/go-srv-demo.yaml
for service in ${SERVICES[@]}; do
kubectl apply -n ${namespace} -f ./resources/services/service-$service.yaml
done
kubectl apply -n ${namespace} -f ./resources/services/angular-ui.yaml
done
You can’t perform that action at this time.