Skip to content

A repository with a Helm chart for deploying an Odoo application to a K8s cluster.

Notifications You must be signed in to change notification settings

sla686/odoo-deployment

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

46 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Helm Chart Assignment

AKS Helm chart deployment

DescriptionPrerequisitesInstallationRemoval

Description

  • This is a Helm chart repository for deploying an odoo application to a Kubernetes cluster.
  • The repository's CI/CD pipeline is configured to deploy application's Helm chart to Azure Kubernetes Service (AKS).

Prerequisites

Kubernetes cluster must be at least version 1.23.x or higher, and be configured with the following:

  1. An ingress controller with ingressClassName ngnix.
  2. A CSI provisioner for volumes.
  3. Optional - configure a public DNS name for your Ingress Controller external IP.

The following tools must be installed on your machine:

  1. kubectl command-line tool.
  2. Helm package manager.

Installation

  1. Clone the repository:
git clone https://github.com/sla686/odoo-assignment.git odoo-app
cd odoo-app
  1. Export KUBECONFIG variable pointing to the kubernetes configuration file:
export KUBECONFIG=/path/to/kubeconfig
  1. Create a new namespace for your application if you need:
kubectl create namespace <application-namespace>
  1. To install the application, you have to provide connection credentials so that the application can connect to the database. In addition, you have to provide the host address for your Ingress configuration. You can specify them in your values.yaml file:
odooApp:
  ingress:
    host: <ingress-controller-dns-name> OR <ingress-controller-public-IP>
odooDB:
  credentials:
    user: <user>
    password: <password>
    database: <database>

Note: If you would like to specify external IP of the Ingress Controller, provide it in the following format: x.x.x.x.nip.io

  1. After that, run the following command to install the application:
helm install --namespace <application-namespace> <application-name> .

You can also provide the connection credentials directly to the command without editing the values.yaml file:

helm install --namespace <application-namespace> \
  --set odooDB.credentials.user=<user> \
  --set odooDB.credentials.password=<password> \
  --set odooDB.credentials.database=<database> \
  --set odooApp.ingress.host=<ingress-controller-dns-name> OR <ingress-controller-public-IP> \
  <application-name> .
  1. Check details about your release:
helm status -n <application-namespace> <application-name>

The application will be hosted on the host which is specified on the ingress. Get the hostname of your application:

kubectl get ingress -n <application-namespace> -o=jsonpath='{.items[0].spec.rules[0].host}'

Then use the output as a link and navigate to it in your browser.

Removal

You can uninstall the application with the following command:

helm uninstall -n <application-namespace> <application-name>

Don't forget to remove the namespace from your Kubernetes cluster if you don't need it anymore:

kubectl delete namespace <application-namespace>

About

A repository with a Helm chart for deploying an Odoo application to a K8s cluster.

Topics

Resources

Stars

Watchers

Forks