am
by Gravitee.io
Official Gravitee.io Helm chart for Access Management
About this chart
Gravitee.io Access Management Helm Chart
Chart supported versions: 2.10.x and higher
Versioning change
After version 1.0.56, version of the Helm Chart will be aligned with the product version. eg:
- If you want to use AM version 3.x.y you have to use the Chart version 3.x.y
- If you want to use AM version 3.x.z you have to use the Chart version 3.x.z
Components
This chart will deploy the following:
- Gravitee UI
- Gravitee API
- Gravitee Access Gateway
- MongoDB replica-set (optional dependency)
Installing
- Add the Gravitee.io helm charts repo
$ helm repo add graviteeio https://helm.gravitee.io - Install it
$ helm install --name graviteeio-am graviteeio/am
Note: If you're using Helm 3, the name parameter is no more valid. Please check https://helm.sh/docs/faq/#release-names-are-now-scoped-to-the-namespace
Create a chart archive
To package this chart directory into a chart archive, run:
$ helm package .
Installing the Chart
To install the chart from the Helm repository with the release name graviteeio-am:
$ helm install --name graviteeio-am graviteeio/am
To install the chart using the chart archive, run:
$ helm install am-1.0.0.tgz
Configuration
The following tables list the configurable parameters of the Gravitee chart and their default values.
You can rely on kubernetes ConfigMaps and Secrets to initialize Gravitee settings since AM 3.15.0. To use this feature, you have to create the ServiceAccount that allows AM to connect to the Kubernetes API (the helm chart should do it by default) and then you simply have to define your application settings like this:
- for a Secret :
kubernetes://<namespace>/secrets/<my-secret-name>/<my-secret-key> - for a ConfigMap :
kubernetes://<namespace>/configmaps/<my-configmap-name>/<my-configmap-key>
Here is an example for the mongodb uri initialized from the mongo secret deployed in the default namespace:
mongo:
uri: kubernetes://default/secrets/mongo/mongouri
If you need to access a secret, you have to create a role within your namespace.
If you are deploying in another namespace and you need to access a secret there, you have to create a separate role in that namespace. The two roles can have the same name, but they are completely separate objects - each role only gives access to the namespace it is created in.
For more information about roles, see Role and ClusterRole in the Kubernetes documentation.
Shared configuration
To configure common features such as:
- chaos testing (see chaoskube chart)
- configuration database (see mongodb-replicaset
| Parameter | Description | Default |
|---|---|---|
chaos.enabled | Enable Chaos test | false |
Mongo
MongoDB connections
There are three ways to configure MongoDB connections.
The most simple is to provide the MongoDB URI.
| Parameter | Description | Default |
|---|---|---|
mongo.uri | Mongo URI | null |
If no mongo.uri is provided, you can provide a mongo.servers raw definition in combination with mongo.dbname, plus
eventual authentication configuration:
mongo:
servers: |
- host: mongo1
port: 27017
- host: mongo2
port: 27017
dbname: gravitee
auth:
enabled: false
username:
password:
If neither mongo.uri or mongo.servers are provided, you have to define the following configuration options:
| Parameter | Description | Default |
|---|---|---|
mongo.rsEnabled | Whether Mongo replicaset is enabled or not | true |
mongo.rs | Mongo replicaset name | rs0 |
mongo.dbhost | Mongo host address | mongo-mongodb-replicaset |
mongo.dbport | Mongo host port | 27017 |
mongo.dbname | Mongo DB name | gravitee |
mongo.auth.enabled | Enable Mongo DB authentication | false |
mongo.auth.username | Mongo DB username | null |
mongo.auth.password | Mongo DB password | null |
Other keys
| Parameter | Description | Default |
|---|---|---|
mongo.sslEnabled | Enable SSL connection to MongoDB | false |
mongo.socketKeepAlive | Enable keep alive for socket | false |
Mongo ReplicaSet
| Parameter | Description | Default |
|---|---|---|
mongodb-replicaset.enabled | Enable deployment of Mongo replicaset | false |
See MongoDB replicaset for detailed documentation on helm chart.
** Please be aware that the mongodb-replicaset installed by Gravitee is NOT recommended in production and it is just for testing purpose and running AM locally.
Proxy configuration for HTTP clients
To define the proxy settings for HTTP clients used by the Management API and the Gateway, the httpClient section needs to be defined into the values.yaml. This section will be apply on both Gateway and Management API configuration files.
httpClient:
timeout: 10000 # in milliseconds
proxy:
enabled: false
exclude-hosts: # list of hosts to exclude from proxy (wildcard hosts are supported)
- '*.internal.com'
- internal.gravitee.io
type: HTTP #HTTP, SOCK4, SOCK5
http:
host: localhost
port: 3128
username: user
password: secret
https:
host: localhost
port: 3128
username: user
password: secret
Application client secret configuration
Since AM 4.2.0, the client secret can be hashed when stored into the database. To specify which hash algorithm is in used, you have to adapt this section into the values.yaml:
applications:
secret:
# Algorithms used to hash the client secret.
# Can be one of :
# "PBKDF2", "BCrypt", "SHA-512", "SHA-256", "None"
algorithm: None
#properties:
# rounds: 4
For BCrypt, the number of rounds can be specified using the rounds property (default set to 10).
For PBKDF2, the number of iterations, the salt length and the algorithm can be specified using :
- the
roundsproperty (default set to 600000) - the
saltproperty (default set to 16) - the
algorithmproperty (default set to PBKDF2WithHmacSHA256, possible value PBKDF2WithHmacSHA256 & PBKDF2WithHmacSHA512)
Gravitee.io Configuration
| Key | Type | Default | Description |
|---|---|---|---|
| alerts.enabled | bool | +true+ | |
| alerts.endpoints | string[] | +- http://localhost:8072/+ | |
| alerts.security.enabled | bool | +false+ | |
| alerts.security.username | string | +"admin"+ | |
| alerts.security.password | string | +"password"+ | |
| alerts.options.sendEventsOnHttp | bool | +true+ | |
| alerts.options.useSystemProxy | bool | +false+ | |
| alerts.options.connectTimeout | int | +2000+ | |
| alerts.options.idleTimeout | int | +120000+ | |
| alerts.options.keepAlive | bool | +true+ | |
| alerts.options.pipelining | bool | +true+ |
Deploy am with OpenTenant
Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has am on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.
- Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
- Place the chartam is pinned at v4.13.8 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
- ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below opentenant validate opentenant.yaml terraform init && terraform apply