Skip to content

Commit 9ddaa21

Browse files
authored
feat: add openshift single region reference arch (#49)
1 parent eaf23fd commit 9ddaa21

34 files changed

+741
-0
lines changed

aws/rosa-hcp-dual-region/README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Camunda on AWS ROSA with Dual-Region
2+
3+
This folder describes the IaC of Camunda on AWS ROSA.
4+
Instructions can be found on the official documentation: https://docs.camunda.io/docs/self-managed/setup/deploy/amazon/openshift/terraform-setup/

aws/rosa-hcp/README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Camunda on AWS ROSA
2+
3+
This folder describes the IaC of Camunda on AWS ROSA.
4+
Instructions can be found on the official documentation: https://docs.camunda.io/docs/self-managed/setup/deploy/amazon/openshift/terraform-setup/
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# TODO: must be filled for tests integration
Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
locals {
2+
rosa_cluster_name = "my-rosa" # Change this to a name of your choice
3+
4+
rosa_cluster_zones = ["eu-north-1a", "eu-north-1b", "eu-north-1c"] # Adjust to your needs and align with your value of AWS_REGION
5+
6+
rosa_admin_username = "kubeadmin"
7+
rosa_admin_password = "CHANGEME1234r!" # Change the password of your admin password
8+
}
9+
10+
module "rosa_cluster" {
11+
source = "git::https://github.com/camunda/camunda-tf-rosa//modules/rosa-hcp?ref=v2.0.0"
12+
13+
cluster_name = local.rosa_cluster_name
14+
15+
availability_zones = local.rosa_cluster_zones
16+
17+
# Set CIDR ranges or use the defaults
18+
vpc_cidr_block = "10.0.0.0/16"
19+
machine_cidr_block = "10.0.0.0/18"
20+
service_cidr_block = "10.0.128.0/18"
21+
pod_cidr_block = "10.0.64.0/18"
22+
23+
# admin access
24+
htpasswd_username = local.rosa_admin_username
25+
htpasswd_password = local.rosa_admin_password
26+
27+
# Default node type for the OpenShift cluster
28+
compute_node_instance_type = "m7i.xlarge"
29+
replicas = 6
30+
}
31+
32+
# Outputs of the parent module
33+
34+
output "public_subnet_ids" {
35+
value = module.rosa_cluster.public_subnet_ids
36+
description = "A comma-separated list of public subnet IDs in the VPC. These subnets are typically used for resources that require internet access."
37+
}
38+
39+
output "private_subnet_ids" {
40+
value = module.rosa_cluster.private_subnet_ids
41+
description = "A comma-separated list of private subnet IDs in the VPC. These subnets are typically used for internal resources that do not require direct internet access."
42+
}
43+
44+
output "cluster_id" {
45+
value = module.rosa_cluster.cluster_id
46+
description = "The unique identifier of the OpenShift cluster created on Red Hat OpenShift Service on AWS (ROSA). This ID is used to reference the cluster in subsequent operations."
47+
}
48+
49+
output "oidc_provider_id" {
50+
value = module.rosa_cluster.oidc_provider_id
51+
description = "OIDC provider for the ROSA cluster. Allows adding additional IAM Role for Service Accounts (IRSA) mappings."
52+
}
53+
54+
output "aws_caller_identity_account_id" {
55+
value = module.rosa_cluster.aws_caller_identity_account_id
56+
description = "The AWS account ID of the caller. This is the account under which the Terraform code is being executed."
57+
}
58+
59+
output "openshift_api_url" {
60+
value = module.rosa_cluster.openshift_api_url
61+
description = "The endpoint URL for accessing the OpenShift API. This endpoint is used to interact with the OpenShift cluster's API server."
62+
}
63+
64+
output "cluster_console_url" {
65+
value = module.rosa_cluster.cluster_console_url
66+
description = "The URL endpoint for accessing the OpenShift web console. This endpoint provides a web-based user interface for managing the OpenShift cluster."
67+
}
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
terraform {
2+
required_version = ">= 1.0"
3+
4+
required_providers {
5+
aws = {
6+
source = "hashicorp/aws"
7+
version = ">= 5.35.0"
8+
}
9+
rhcs = {
10+
version = "1.6.6"
11+
source = "terraform-redhat/rhcs"
12+
}
13+
}
14+
15+
backend "s3" {
16+
encrypt = true
17+
}
18+
}
19+
20+
# ensure RHCS_TOKEN env variable is set with a value from https://console.redhat.com/openshift/token/rosa
21+
provider "rhcs" {}
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
disable=SC2148,SC2155
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# The Camunda 8 Helm Chart version
2+
# renovate: datasource=helm depName=camunda-platform versioning=regex:^11(\.(?<minor>\d+))?(\.(?<patch>\d+))?$ registryUrl=https://helm.camunda.io
3+
export CAMUNDA_HELM_CHART_VERSION="11.0.4"
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
kubectl create secret generic identity-secret-for-components \
2+
--namespace camunda \
3+
--from-literal=connectors-secret="$CONNECTORS_SECRET" \
4+
--from-literal=console-secret="$CONSOLE_SECRET" \
5+
--from-literal=operate-secret="$OPERATE_SECRET" \
6+
--from-literal=optimize-secret="$OPTIMIZE_SECRET" \
7+
--from-literal=tasklist-secret="$TASKLIST_SECRET" \
8+
--from-literal=zeebe-secret="$ZEEBE_SECRET" \
9+
--from-literal=admin-password="$ADMIN_PASSWORD" \
10+
--from-literal=smtp-password=""
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
export CONNECTORS_SECRET="$(openssl rand -hex 16)"
2+
export CONSOLE_SECRET="$(openssl rand -hex 16)"
3+
export OPERATE_SECRET="$(openssl rand -hex 16)"
4+
export OPTIMIZE_SECRET="$(openssl rand -hex 16)"
5+
export TASKLIST_SECRET="$(openssl rand -hex 16)"
6+
export ZEEBE_SECRET="$(openssl rand -hex 16)"
7+
export ADMIN_PASSWORD="$(openssl rand -hex 16)"
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
---
2+
global:
3+
elasticsearch:
4+
enabled: true # use the embbeded elasticsearch
5+
6+
identityKeycloak:
7+
postgresql:
8+
enabled: true # use the embbeded database
9+
auth:
10+
existingSecret: identity-secret-for-components
11+
12+
console:
13+
enabled: false # by default, console is not enabled
14+
15+
webModeler:
16+
enabled: false # by default, webModeler is not enabled
17+
18+
restapi:
19+
mail:
20+
existingSecret: identity-secret-for-components # reference the smtp password
21+
fromAddress: [email protected] # change this required value

0 commit comments

Comments
 (0)