Skip to content

Commit

Permalink
🚀 deploy odoo
Browse files Browse the repository at this point in the history
  • Loading branch information
nikhiljha committed Apr 21, 2024
1 parent e99dab3 commit 34fe5f3
Show file tree
Hide file tree
Showing 3 changed files with 62 additions and 0 deletions.
56 changes: 56 additions & 0 deletions apps/odoo.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
from transpire import helm
from transpire.utils import get_versions

name = "odoo"


def objects():
yield {
"apiVersion": "acid.zalan.do/v1",
"kind": "postgresql",
"metadata": {"name": "ocf-odoo-db"},
"spec": {
"teamId": "ocf",
"volume": {
"size": "128Gi",
"storageClass": "rbd-nvme",
},
"numberOfInstances": 1,
"users": {"odoo": ["superuser", "createdb"]},
"databases": {"odoo": "odoo"},
"postgresql": {"version": "15"},
},
}

yield from helm.build_chart_from_versions(
name=name,
versions=get_versions(__file__),
values={
# Database
"postgresql": {
"enabled": False,
},
"externalDatabase": {
"host": "ocf-odoo-db",
"port": 5432,
"user": "odoo",
"database": "odoo",
"existingSecret": "odoo.ocf-odoo-db.credentials.postgresql.acid.zalan.do",
"existingSecretPasswordKey": "password",
},
# Mail
"smtpHost": "smtp.ocf.berkeley.edu",
# Ingress
"ingress": {
"enabled": True,
"ingressClassName": "contour",
"annotations": {
"cert-manager.io/cluster-issuer": "letsencrypt",
"ingress.kubernetes.io/force-ssl-redirect": "true",
"kubernetes.io/tls-acme": "true",
},
"hostname": "odoo.ocf.berkeley.edu",
"tls": True,
},
},
)
4 changes: 4 additions & 0 deletions apps/versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,10 @@ helm = "https://kubernetes-sigs.github.io/metrics-server/"
version = "0.3.0"
helm = "https://harbor.ocf.berkeley.edu/chartrepo/mycelium"

[odoo]
version = "26.0.0"
helm = "https://charts.bitnami.com/bitnami"

[postgres-operator]
version = "1.10.1"
helm = "https://opensource.zalando.com/postgres-operator/charts/postgres-operator"
Expand Down
2 changes: 2 additions & 0 deletions cluster.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ metrics-server = { path = "apps/metrics_server.py" }
prometheus = { path = "apps/prometheus.py" }
postgres-operator = { path = "apps/postgres_operator.py" }
ocf-io = { path = "apps/ocf_io.py" }
odoo = { path = "apps/odoo.py" }
rabbitmq = { path = "apps/rabbitmq.py" }
rook = { path = "apps/rook.py" }
snapshot-controller = { path = "apps/snapshot_controller.py" }
Expand All @@ -51,3 +52,4 @@ ocfweb = { git = "https://github.com/ocf/ocfweb" }
outline = { git = "https://github.com/ocf/outline" }
templates = { git = "https://github.com/ocf/templates" }
transpire = { git = "https://github.com/ocf/transpire" }

0 comments on commit 34fe5f3

Please sign in to comment.