-
Notifications
You must be signed in to change notification settings - Fork 59
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Tommy Hughes <[email protected]>
- Loading branch information
1 parent
a36ccd0
commit 56be189
Showing
4 changed files
with
115 additions
and
83 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
106 changes: 106 additions & 0 deletions
106
serverlessworkflow/modules/ROOT/pages/cloud/operator/supporting-services.adoc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,106 @@ | ||
= Supporting Services | ||
:compat-mode!: | ||
// Metadata: | ||
:description: Deploy Supporting Services with {operator_name} | ||
:keywords: kogito, sonataflow, workflow, serverless, operator, kubernetes, openshift, containers, data, index, job, service | ||
// links | ||
:kogito_serverless_operator_url: https://github.com/apache/incubator-kie-kogito-serverless-operator/ | ||
|
||
By default, workflows use an embedded version of xref:data-index/data-index-core-concepts.adoc[Data Index]. This document describes how to deploy supporting services, like Data Index, on a cluster using the link:{kogito_serverless_operator_url}[{operator_name}]. | ||
|
||
[IMPORTANT] | ||
==== | ||
{operator_name} is under active development with features yet to be implemented. Please see xref:cloud/operator/known-issues.adoc[]. | ||
==== | ||
|
||
.Prerequisites | ||
* The {operator_name} installed. See xref:cloud/operator/install-serverless-operator.adoc[] guide | ||
* A postgresql database, if persistence is required | ||
[#deploy-supporting-services] | ||
== Deploy supporting services | ||
|
||
=== Data Index | ||
|
||
You can deploy Data Index via `SonataFlowPlatform` configuration. The operator will then configure all new workflows, with the "prod" profile, to use that Data Index. | ||
|
||
Following is a basic configuration. It will deploy an ephemeral Data Index to the same namespace as the `SonataFlowPlatform`. | ||
|
||
.Example of a SonataFlowPlatform instance with an ephemeral Data Index deployment | ||
[source,yaml,subs="attributes+"] | ||
---- | ||
apiVersion: sonataflow.org/v1alpha08 | ||
kind: SonataFlowPlatform | ||
metadata: | ||
name: sonataflow-platform | ||
spec: | ||
services: | ||
dataIndex: {} | ||
---- | ||
|
||
If you require Data Index persistence, this can be done with a `postgresql` database. | ||
|
||
Following is a services configuration with the persistence option enabled. You'll first need to create a secret with your database credentials. | ||
|
||
.Create a Secret for datasource authentication. | ||
[source,bash,subs="attributes+"] | ||
---- | ||
kubectl create secret generic <creds-secret> --from-literal=POSTGRESQL_USER=<user> --from-literal=POSTGRESQL_PASSWORD=<password> -n workflows | ||
---- | ||
|
||
.Example of a SonataFlowPlatform instance with a Data Index deployment persisted to a postgresql database | ||
[source,yaml,subs="attributes+"] | ||
---- | ||
apiVersion: sonataflow.org/v1alpha08 | ||
kind: SonataFlowPlatform | ||
metadata: | ||
name: sonataflow-platform | ||
spec: | ||
services: | ||
dataIndex: | ||
persistence: | ||
postgresql: | ||
secretRef: | ||
name: <creds-secret> <1> | ||
serviceRef: | ||
name: <postgresql-service> <2> | ||
---- | ||
|
||
<1> Name of your postgresql credentials secret | ||
<2> Name of your postgresql k8s service | ||
|
||
.Example of a SonataFlowPlatform instance with a persisted Data Index deployment and custom pod configuration | ||
[source,yaml,subs="attributes+"] | ||
---- | ||
apiVersion: sonataflow.org/v1alpha08 | ||
kind: SonataFlowPlatform | ||
metadata: | ||
name: sonataflow-platform | ||
spec: | ||
services: | ||
dataIndex: | ||
enabled: false <1> | ||
persistence: | ||
postgresql: | ||
secretRef: | ||
name: <creds-secret> | ||
userKey: <secret-user-key> <2> | ||
jdbcUrl: "jdbc:postgresql://host:port/database?currentSchema=data-index-service" <3> | ||
podTemplate: | ||
replicas: 1 <4> | ||
container: | ||
image: <image:tag> <5> | ||
---- | ||
|
||
<1> Determines whether "prod" profile workflows should be configured to use this service, defaults to `true` | ||
<2> Secret key of your postgresql credentials user, defaults to `POSTGRESQL_USER` | ||
<3> PostgreSql JDBC URL | ||
<4> Number of Data Index pods, defaults to `1` | ||
<5> Custom Data Index container image name | ||
|
||
== Additional resources | ||
|
||
* xref:data-index/data-index-service.adoc[] | ||
* xref:cloud/operator/known-issues.adoc[] | ||
|
||
include::../../../pages/_common-content/report-issue.adoc[] |