Dapr Configurations
🟢 Management
Opstella has designed with Dapr to cooperate between its microservices,
add configurations of Dapr within opstella-system is required to Opstella to function properly.
Preparation
Section titled “Preparation”-
Connect to
🟢 ManagementKubernetes Cluster ; i.e w/ Kubeconfig FileTerminal window export KUBECONFIG="$HOME/opstella-installation/kubeconfigs/management_cluster.yaml" -
Prepare
🟢 ManagementKubernetes Cluster InformationEnsure
K8S_INTERNAL_DOMAINis defined as per the Shell Variables guide.
Install Dapr Components CRDs
Section titled “Install Dapr Components CRDs”-
Install Pub/Sub Broker
Use the Redis that you previously installed Host and Credentials.
export REDIS_HOST="redis-sentinel-opstella.opstella-system.svc:26379"export REDIS_PASSWORD="CHANGEME"Terminal window kubectl apply --namespace opstella-system -f - <<EOFapiVersion: dapr.io/v1alpha1kind: Componentspec:type: pubsub.redisversion: v1metadata:- name: redisHostvalue: ${REDIS_HOST}- name: redisSentinelMasterNamevalue: redis-opstella- name: redisTypevalue: sentinel- name: enableTLSvalue: 'false'- name: redisPasswordvalue: ${REDIS_PASSWORD}metadata:name: pubsubEOF -
Install Statestore Component
Use the Redis that you previously installed Host and Credentials.
Terminal window kubectl apply --namespace opstella-system -f - <<EOFapiVersion: dapr.io/v1alpha1kind: Componentspec:type: state.redisversion: v1metadata:- name: redisHostvalue: ${REDIS_HOST}- name: redisSentinelMasterNamevalue: redis-opstella- name: redisTypevalue: sentinel- name: keyPrefixvalue: none- name: redisPasswordvalue: ${REDIS_PASSWORD}metadata:name: statestoreEOF
Install Dapr Configurations CRDs
Section titled “Install Dapr Configurations CRDs”-
Install Resiliency
Terminal window kubectl apply --namespace opstella-system -f - <<EOFapiVersion: dapr.io/v1alpha1kind: Resiliencyspec:policies:retries:DaprBuiltInServiceRetries:policy: constantduration: 2smaxRetries: 5DefaultServiceInvocationRetries:policy: constantduration: 1smaxRetries: 3pubsubRetry:policy: constantduration: 30smaxRetries: 10targets:components:pubsub:inbound:retry: pubsubRetrymetadata:name: resiliencyEOF -
Install Kubernetes Name Resolution Configuration
Terminal window kubectl apply --namespace opstella-system -f - <<EOFapiVersion: dapr.io/v1alpha1kind: Configurationspec:nameResolution:version: v1component: "kubernetes"configuration:clusterDomain: ${K8S_INTERNAL_DOMAIN}metadata:name: configEOF
Finished?
Use the below navigation to proceed