Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chart added for metabase service #674

Open
wants to merge 9 commits into
base: main
Choose a base branch
from
43 changes: 25 additions & 18 deletions charts/dataingestion-service/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -67,31 +67,38 @@ spec:
name: ldfdata-reporting-service
port:
number: {{ .Values.reportingService.ldfdataReportingServicePort }}
{{- end }}
{{- if eq .Values.dataprocessingService.enabled "true" }}
- path: "/rti/"
- path: "/reporting/metabase"
pathType: Prefix
backend:
service:
name: data-processing-service
name: metabase-service
port:
number: {{ .Values.dataprocessingService.port }}
{{- end }}
{{- if eq .Values.srtedataService.enabled "true" }}
number: {{ .Values.reportingService.metabaseServicePort }}
{{- end }}
{{- if eq .Values.dataprocessingService.enabled "true" }}
- path: "/rti/"
pathType: Prefix
backend:
service:
name: srte-data-service
name: data-processing-service
port:
number: {{ .Values.srtedataService.port }}
number: {{ .Values.dataprocessingService.port }}
{{- end }}
{{- if eq .Values.srtedataService.enabled "true" }}
- path: "/extraction/"
pathType: Prefix
backend:
service:
name: nnd-service
port:
number: {{ .Values.nndService.port }}
{{- end }}
{{/* {{- if eq .Values.srtedataService.enabled "true" }}*/}}
{{/* - path: "/rti/"*/}}
{{/* pathType: Prefix*/}}
{{/* backend:*/}}
{{/* service:*/}}
{{/* name: srte-data-service*/}}
{{/* port:*/}}
{{/* number: {{ .Values.srtedataService.port }}*/}}
{{/* {{- end }} */}}
{{/* {{- if eq .Values.srtedataService.enabled "true" }}*/}}
{{/* - path: "/extraction/"*/}}
{{/* pathType: Prefix*/}}
{{/* backend:*/}}
{{/* service:*/}}
{{/* name: nnd-service*/}}
{{/* port:*/}}
{{/* number: {{ .Values.nndService.port }}*/}}
{{/* {{- end }} */}}
1 change: 1 addition & 0 deletions charts/dataingestion-service/values-dev.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ reportingService:
observationReportingServicePort: 8094
postProcessingReportingServicePort: 8095
ldfdataReportingServicePort: 8097
metabaseServicePort: 8190

dataprocessingService:
enabled: "false"
Expand Down
1 change: 1 addition & 0 deletions charts/dataingestion-service/values-dts1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ reportingService:
observationReportingServicePort: 8094
postProcessingReportingServicePort: 8095
ldfdataReportingServicePort: 8097
metabaseServicePort: 8190

dataprocessingService:
enabled: "true"
Expand Down
1 change: 1 addition & 0 deletions charts/dataingestion-service/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ reportingService:
observationReportingServicePort: 8094
postProcessingReportingServicePort: 8095
ldfdataReportingServicePort: 8097
metabaseServicePort: 8190

dataprocessingService:
enabled: "true"
Expand Down
21 changes: 21 additions & 0 deletions charts/metabase-service/.helmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Patterns to ignore when building packages.
# This supports shell glob matching, relative path matching, and
# negation (prefixed with !). Only one pattern per line.
.DS_Store
# Common VCS dirs
.git/
.gitignore
.bzr/
.bzrignore
.hg/
.hgignore
.svn/
# Common backup files
*.swp
*.bak
*.tmp
*~
# Various IDEs
.project
.idea/
*.tmproj
13 changes: 13 additions & 0 deletions charts/metabase-service/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
apiVersion: v1
description:
The easy, open source way for everyone in your company to ask questions
and learn from data.
name: metabase
# Update this value everytime, we change anything in the repo
version: 2.7.3
# This is the version value from the official metabase repo
appVersion: v0.51.4
home: http://www.metabase.com/
icon: http://www.metabase.com/images/logo.svg
sources:
- https://github.com/metabase/metabase
88 changes: 88 additions & 0 deletions charts/metabase-service/Metabase_Installation.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
# Metabase Installation on EKS using Helm charts

This document will help understand the installation and running of
Metabase on AWS EKS, using Helm charts. This Metabase page can be
accessed from any browser from [EQ Metabase
Instance](https://metabase.datateam-cdc-nbs.eqsandbox.com/).

## Prerequisites

- EKS instance is running and you are added to the admin role to
install and run the containers

- RDS (Postgres) for App DB running on the same VPC

- **Install Kubernetes CLI tool** on your local machine to interact
with containers on the EKS cluster

- <https://kubernetes.io/docs/tasks/tools/install-kubectl-macos/>

- **Install Helm CLI tool** on your local machine to run commands on
the containers on the EKS cluster

- For installation on Mac OS:

- Make sure that your home brew package manager is up-to-date
-- brew update

- Install helm using home brew -- brew install helm

- Verify the installation -- helm version

## Installing Metabase using EKS

### Connecting to the EKS Cluster:

- Go to the AWS login page and click on Command line or Programmatic
access

We need to have Admin access to the AWS console, in order to access the
cluster to install and run kubernetes containers

- Select one of the options to Get the credentials to access the
console using the command line access, in our case we are selecting
the Option 1: Set AWS environment variables (Short-term credentials)

- Copy and run the above export commands for the credentials into the
terminal

- Run the below command on your terminal to connect to the eks cluster
using the provided the role

> aws eks --region us-east-1 update-kubeconfig --name cdc-nbs-dts1-eks

### Installing Metabase (PostgreSQL as App DB):

- Following command will install and run the Metabase on the EKS
cluster

- use the metabase-config.yaml file to provide the additional
connection parameters such as PostgreSQL database information
for the Metabase's App DB, and also used to provide the App
version information, etc.

> helm install metabase <helm_chart_path\> -f <path\>/values.yaml

Before proceeding to Installation we need to make sure that our EKS
and RDS are connected to allow traffic going both ways.

Please make sure you pass the correct path for the helm chart and
path for the yaml file

- Now you should be able to access the Metabase Instance from the host
name provided in the ingress rules (check your values\_\<env\>.yaml)

If you don't have a DNS setup available for metabase, use the following
steps to access the metabase instance from the POD ip address

### Accessing Metabase from browser:

- Once the installation is done, we can access metabase app on the
same IP address as the metabase pod, and on port 3000.

- Run the command kubectl get pods -o wide to identify the IP
address of the POD running Metabase server

![](media/image4.png)

example: In the current installation you can access metabase from: http://<pod-ip-address>:3000/
Loading
Loading