GithubHelp home page GithubHelp logo

zhaopufeng / activiti-cloud-full-chart Goto Github PK

View Code? Open in Web Editor NEW

This project forked from activiti/activiti-cloud-full-chart

0.0 1.0 0.0 19.96 MB

Umbrella Helm chart for Activiti Cloud

License: Apache License 2.0

Makefile 79.22% Smarty 20.78%

activiti-cloud-full-chart's Introduction

activiti-cloud-full-chart

Getting Started Guide

More information:

Running on Docker Desktop

Install Docker Desktop and make sure the included single node Kubernetes cluster is started.

Install the latest version of Helm.

Add the magic host.docker.internal hostname to your hosts file:

sudo echo "127.0.0.1        host.docker.internal" > /etc/hosts

Install a recent version of ingress-nginx:

helm install --repo https://kubernetes.github.io/ingress-nginx ingress-nginx ingress-nginx --version 2.16.0

Update all dependencies:

helm dependency update charts/activiti-cloud-full-example

Create Activiti Keycloak Client Kubernetes secret in the activiti namespace:

kubectl create secret generic activiti-keycloak-client \
   --namespace activiti \
   --from-literal=clientId=activiti-keycloak \
   --from-literal=clientSecret=`uuidgen`

Create a values.yaml file with any customised values from the default values.yaml you want, as documented in the chart README.

In your local installation to start with, this would be:

global:
  gateway:
    host: host.docker.internal
  keycloak:
    host: host.docker.internal
    clientSecretName: activiti-keycloak-client
    useExistingClientSecret: true

Alternatively, you can create Activiti Keycloak Client Kubernetes secret with Helm with the following values:

global:
  gateway:
    host: host.docker.internal
  keycloak:
    host: host.docker.internal
    clientSecret: changeit

In a generic cluster install, you can just add --set global.gateway.domain=$YOUR_CLUSTER_DOMAIN to the helm command line, provided your DNS is configured with a wildcard entry *.$YOUR_CLUSTER_DOMAIN pointing to your cluster ingress.

Install or upgrade an existing installation:

helm upgrade --install \
  --atomic --create-namespace --namespace activiti \
  -f values.yaml \
  activiti charts/activiti-cloud-full-example

Uninstall:

helm uninstall --namespace activiti activiti

WARNING All the PVCs are not deleted by helm uninstall and that should be done manually unless you want to keep data for another install.

kubectl get pvc --namespace activiti
kubectl delete pvc --namespace activiti ...

or just delete the namespace fully:

kubectl delete ns activiti

As an alternative, generate a Kubernetes descriptor you can analyse or apply offline using kubectl apply -f output.yaml:

helm template --validate \
  --atomic --create-namespace --dependency-update --namespace activiti \
  -f values.yaml \
  activiti charts/activiti-cloud-full-example

Enabling message partitioning

In order to enable partitioning provide the following extra values (partitionCount defines how many partitions will be used and the Helm deployment will create that many replicaSets of query service and configure Rb service with the number of supported partitions in Query):

global:
  messaging:
    # global.messaging.partitioned -- enables partitioned messaging in combination with messaging.enabled=true && messaging.role=producer|consumer
    partitioned: true
    # global.messaging.partitionCount -- configures number of partitioned consumers
    partitionCount: 2

Use Kafka instead of Rabbit MQ

In order to switch the message broker to Kafka add the following extra values

global:
  messaging:
    broker: kafka
kafka:
  enabled: true
rabbitmq:
  enabled: false

Message Partitioning with Kafka

Kafka has different architecture from RabbitMQ. One Kafka topic can be served by a number of partitions independent from the consumer number (greater or equal).

Configuring the Kafka broker in the helm chart it is possible to specify partitionCount greater or equal to the replicaCount (the consumer number). Defining these two number independently allow the user to instantiate consumers only if it is needed, avoiding to waste resources.

global:
  messaging:
    partitioned: true
    # global.messaging.partitionCount -- set the Kafka partition number
    partitionCount: 4

activiti-cloud-query:
  # replicaCount -- set the Kafka consumer number
  replicaCount: 2

Skipping CI

If you want to skip running release pipeline stages, simply add [ci skip] to your commit message.

CI/CD

Running on Travis, requires the following environment variable to be set:

Name Description
MAVEN_USERNAME Internal Maven repository username
MAVEN_PASSWORD Internal Maven repository password
GITHUB_TOKEN Github token for git service account
GITHUB_USER Github user name for git service account
K8S_API_TOKEN Kubernetes API token
K8S_API_URL Kubernetes API url

activiti-cloud-full-chart's People

Contributors

almerico avatar erdemedeiros avatar gicappa avatar igdianov avatar jesty avatar mergify[bot] avatar miguelruizdev avatar mteodori avatar pow-devops2020 avatar salaboy avatar vitoalbano avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.