Skip to content

pabblo17/enron-mail-challenge

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Enron Mail Challenge

Application to search for a term in the content of an email in a database

client

Zinc Search (Installation)

Ref. link

Installation - Local

S.O.: Ubuntu-22.04 (WSL Windows)

Download version: releases-zinc-search.

Use in this case: zinc_0.3.5_Linux_arm64.tar.gz

Unzip the contents, preferably in a new folder

  tar -xvf zinc_0.3.5_Linux_arm64.tar.gz

Create a data folder that will store the data

mkdir data

Use to start

  ZINC_FIRST_ADMIN_USER=admin ZINC_FIRST_ADMIN_PASSWORD=Complexpass#123 ./zinc

Now point your browser to http:https://localhost:4080 and login

Installation - Kubernetes (minikube)

Create a namespace:

kubectl create ns zinc

Create the deployment and port forward:

kubectl apply -f zinc-search/k8s-manifest/kube-deployment.yaml

The service is configured as NodePort

Now point your browser to http:https://localhost:30000 and login or can be made available with an ingress or port-forward:

kubectl -n zinc port-forward svc/zinc 4080:4080

Installation - Helm Kubernetes (minikube)

Update Helm values located in values.yaml

Create the namespace:

kubectl create ns zinc

Install the chart:

helm install zinc -f zinc-search/helm/values.yaml --namespace zinc

The service is configured as NodePort

Now point your browser to http:https://localhost:30000 and login or can be made available with an ingress or port-forward:

kubectl -n zinc port-forward svc/zinc 4080:4080

Other option is create chart and install

helm package /zinc-search/helm/zinc --version 1.0.0

helm install -f zinc-search/helm/values.yaml zinc zinc-1.0.0.tgz --namespace zinc

Indexer Mails (zinc-search-indexer)

download data in enron_mail_2011040

  • Configure and add enviroments use sample file .env.sample

    ZINC_SEARCH_HOST="http:https://localhost:[PORT]/api/"
    ZINC_SEARCH_INDEX="mail"
    ZINC_SEARCH_USER="admin"
    ZINC_SEARCH_PASSWORD="Complexpass#123"
    BATCH_SIZE=500
  • Download dependencies

    go mod download
  • Build app

    go build -o indexer
  • Run indexer

    ./indexer [path of mails to indexer]

Server API (api-search-enton-mail)

  • Configure and add enviroments use sample file .env.sample

    ZINC_SEARCH_HOST="http:https://localhost:[PORT]/api/"
    ZINC_SEARCH_HOST_ES="http:https://localhost:[PORT]/es/"
    ZINC_SEARCH_USER="admin"
    ZINC_SEARCH_PASSWORD="Complexpass#123"
    PORT=8080
  • Download dependencies

    go mod download
  • Build app

    go build -o api-search
  • Run indexer

    ./api-search

Cliente APP (cli-enron-mail)

  • Configure and add enviroments use sample file .env.sample

    VUE_APP_SEARCH_API_SERVICE_HOST=http:https://localhost:[PORT]/api/
    VUE_APP_SEARCH_API_SERVICE_QUERY=http:https://localhost:[PORT]/api/search
    VUE_APP_SEARCH_API_SERVICE_FIND=http:https://localhost:[PORT]/api/search/id
    VUE_APP_SEARCH_API_INDEX=mail
  • Install project dependencies

    npm install
  • Run app

    npm run serve -- --port 3000
  • Go localhost:3000

Author

@PabloChandi