From 6cdfeb15902b7fcc4b50db51ea835d6723dbbc19 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Rold=C3=A1n?= <62166813+Odraxs@users.noreply.github.com> Date: Thu, 21 Mar 2024 15:06:02 -0500 Subject: [PATCH] Change code to work with env vars (#19) * Add code improvements * Update readme * Update config tests --- README.md | 16 ++++++++++++---- data-embedding/main.go | 12 ++++++++---- data-embedding/profs/cpu.prof | Bin 449 -> 434 bytes data-embedding/profs/mem.prof | Bin 17811 -> 18182 bytes docker-compose.yml | 4 ++-- docker/docker-compose.yml | 7 +++++-- envs.sh | 4 ++++ server/config/credentials.go | 12 ++++++++---- server/config/credentials_test.go | 8 ++++++-- server/test/fixtures/config_fixtures.go | 13 +++++++++++++ web/src/services/emails.ts | 2 -- 11 files changed, 58 insertions(+), 20 deletions(-) create mode 100755 envs.sh create mode 100644 server/test/fixtures/config_fixtures.go diff --git a/README.md b/README.md index 790ef0c..969a701 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ This project consist in 4 folders: ## Requirements: -- Go >= 1.22(recommended) +- Go == 1.22 - Docker - Docker-compose - Node >= 20.10.0(recommended) @@ -17,13 +17,15 @@ This project consist in 4 folders: ## I just want to see the project running! -- Give write permission: +- Give permissions: ```bash - | chmod a+rwx ./data-embedding + chmod +x envs.sh + chmod a+rwx ./data-embedding ``` - Only follow the instructions of [data-embedding](#data-embedding) - Then run the following commands: ```bash + . envs.sh cd docker docker-compose up ``` @@ -34,6 +36,12 @@ This project consist in 4 folders: To setup the project first run the following commands: +- Set up env variables(you can modify the file to set the values you want) +```bash + chmod +x envs.sh + . envs.sh +``` + - Give write permission ```bash chmod a+rwx ./data-embedding @@ -129,7 +137,7 @@ To start the web server run: ```bash cd ../web npm i - npm run lin + npm run lint npm run dev ``` diff --git a/data-embedding/main.go b/data-embedding/main.go index 7c8c964..1317652 100644 --- a/data-embedding/main.go +++ b/data-embedding/main.go @@ -25,6 +25,11 @@ const ( dateFormatLayout = "Mon, 2 Jan 2006 15:04:05 -0700 (MST)" ) +var ( + zincUser = os.Getenv("ZINC_USER") + zincPassword = os.Getenv("ZINC_PASSWORD") +) + func main() { log.Println("Starting indexer!") utils.CpuProfiling() @@ -140,8 +145,8 @@ func sendBulkToZincSearch(records []utils.EmailData) { log.Println(err) return } - //TODO: change to .evn latter - req.SetBasicAuth("admin", "password") + + req.SetBasicAuth(zincUser, zincPassword) req.Header.Set("Content-Type", "application/json") req.Header.Set("User-Agent", "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36") @@ -211,8 +216,7 @@ func deleteIndexOnZincSearch(indexName string) error { return err } - //TODO: Change to .env file latter - req.SetBasicAuth("admin", "password") + req.SetBasicAuth(zincUser, zincPassword) client := &http.Client{} resp, err := client.Do(req) diff --git a/data-embedding/profs/cpu.prof b/data-embedding/profs/cpu.prof index 55f011d065cf00f370ef32dee5c2b6c6758fd5ac..c1cfd1bc7982d445d8a276bbbc3891046f24e551 100644 GIT binary patch literal 434 zcmV;j0ZslNiwFP!00004|1^!eZqz^&hS_V(29Sl2vay7+4U(J9c#g-nH=v{@ipZRq zF|y>fS3B`)=}rf4fy+=(1quX33Yt_DJOCGo5|oODBFKT9=KJ+a=ldVNdh_GM+mEMT zb|yoo=k_NbCjXQu;yRcrfvV`YR7;AtX*4Wkc_sZD1Tz3ipA0;9tSsY1?VVFpf2?L={v_!5ULx}R2 zt2~AKtg)+q3Oz52s@cppX*`d`e~}h4mxu}t=OPcYPzb3+CZrUa=V($ML{jkt#s_O{ c>qD3vtnD+aWLX~m4FCZD|Gnp)TjK!$03sgKCjbBd literal 449 zcmV;y0Y3g8iwFP!00004|1^y~YZO5ohrQRV7nMbXY!>9M+~#(6{yY2j4J@qv?u}r@=$G2YZGumRcDYiKeaBFc8ZY_G?}@Mv11D1_)U% zmgKaVV_RuS3(8`MAWsNJ5hZG?h~#TNR|`~9R`n@7CaqZ!T_Mp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O-mzkZBnx2`LkyYTZIa0FHy;?uvdO7AS(*76dAWJ^v~)*mYHo%jCody2FFU88FhARF%gs(J%uLTJ zu-W4DTTx{TOW163o;@!wFFQ9Y(_WC5o}O*b$jxxr(hIT+?0IPgw%j~hW?@!ZeqoMr ziF|uG&QH$DwaMwZ8QBFHh3Pr@x%sKtX=zy*>5e>mer9G)c2-7SR)#G%J2lguZnGr@ zxF{HaeeeNeab&vT@uWfZ38re|c>^D}ZY?DmX;w8A_`PFiZF qJwGkm7XHMu1#ah)HtQ45y2rZn?Ik5o{=WbK0RR6LBtEJ)jsO5~R#->? diff --git a/docker-compose.yml b/docker-compose.yml index f3d8b9f..5500ac5 100755 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -7,7 +7,7 @@ services: - ./data-embedding:/data:Z environment: - ZINC_DATA_PATH=/data - - ZINC_FIRST_ADMIN_USER=admin - - ZINC_FIRST_ADMIN_PASSWORD=password + - ZINC_FIRST_ADMIN_USER=$ZINC_USER + - ZINC_FIRST_ADMIN_PASSWORD=$ZINC_PASSWORD ports: - '4080:4080' diff --git a/docker/docker-compose.yml b/docker/docker-compose.yml index a6b422d..a1503cf 100755 --- a/docker/docker-compose.yml +++ b/docker/docker-compose.yml @@ -7,8 +7,8 @@ services: - ../data-embedding:/data:Z environment: - ZINC_DATA_PATH=/data - - ZINC_FIRST_ADMIN_USER=admin - - ZINC_FIRST_ADMIN_PASSWORD=password + - ZINC_FIRST_ADMIN_USER=$ZINC_USER + - ZINC_FIRST_ADMIN_PASSWORD=$ZINC_PASSWORD ports: - '4080:4080' @@ -16,6 +16,9 @@ services: build: ../server depends_on: - zincsearch + environment: + - ZINC_USER=$ZINC_USER + - ZINC_PASSWORD=$ZINC_PASSWORD ports: - '3001:3001' diff --git a/envs.sh b/envs.sh new file mode 100755 index 0000000..2f0c862 --- /dev/null +++ b/envs.sh @@ -0,0 +1,4 @@ +#!/bin/bash + +export ZINC_USER="admin" +export ZINC_PASSWORD="password" diff --git a/server/config/credentials.go b/server/config/credentials.go index 06bca54..876357a 100644 --- a/server/config/credentials.go +++ b/server/config/credentials.go @@ -1,6 +1,9 @@ package config -import "log" +import ( + "log" + "os" +) type ZincsearchCredentials struct { User string @@ -17,10 +20,11 @@ func LoadZincsearchCredentials() ZincsearchCredentials { log.Println("Loading zincsearch credentials...") credentials := &ZincsearchCredentials{} - // Emulation of config loading since the doc requested to no use any other external library + + // Configure the env vars in the shell, since the doc requested to not use any other external library // so I can't use something like `godotenv` to get the user credentials for a .env file - credentials.User = "admin" - credentials.Password = "password" + credentials.User = os.Getenv("ZINC_USER") + credentials.Password = os.Getenv("ZINC_PASSWORD") zincsearchCredentials = credentials diff --git a/server/config/credentials_test.go b/server/config/credentials_test.go index 4038a0e..fd5e6f7 100644 --- a/server/config/credentials_test.go +++ b/server/config/credentials_test.go @@ -1,12 +1,12 @@ package config_test import ( - "fmt" "reflect" "strings" "testing" "github.com/Odraxs/go-z-v-mail/server/config" + "github.com/Odraxs/go-z-v-mail/server/test/fixtures" ) func TestGetZincsearchCredentials(t *testing.T) { @@ -27,6 +27,7 @@ func TestGetZincsearchCredentials(t *testing.T) { }, } + fixtures.CreateEnvs() for _, test := range test { tt := test t.Run(tt.name, func(t *testing.T) { @@ -35,12 +36,13 @@ func TestGetZincsearchCredentials(t *testing.T) { } credentials := config.GetZincsearchCredentials() - fmt.Printf("-------- %+v", credentials) + if !reflect.DeepEqual(credentials, tt.expected) { t.Fatalf("Expected %v but got %v", tt.expected, credentials) } }) } + fixtures.RemoveEnvs() } func TestLoadZincsearchCredentials(t *testing.T) { @@ -62,6 +64,7 @@ func TestLoadZincsearchCredentials(t *testing.T) { }, }} + fixtures.CreateEnvs() for _, test := range test { tt := test t.Run(tt.name, func(t *testing.T) { @@ -71,4 +74,5 @@ func TestLoadZincsearchCredentials(t *testing.T) { } }) } + fixtures.RemoveEnvs() } diff --git a/server/test/fixtures/config_fixtures.go b/server/test/fixtures/config_fixtures.go new file mode 100644 index 0000000..8ab3342 --- /dev/null +++ b/server/test/fixtures/config_fixtures.go @@ -0,0 +1,13 @@ +package fixtures + +import "os" + +func CreateEnvs() { + os.Setenv("ZINC_USER", "admin") + os.Setenv("ZINC_PASSWORD", "password") +} + +func RemoveEnvs() { + os.Unsetenv("ZINC_USER") + os.Unsetenv("ZINC_PASSWORD") +} diff --git a/web/src/services/emails.ts b/web/src/services/emails.ts index c09ff4b..82f4c26 100644 --- a/web/src/services/emails.ts +++ b/web/src/services/emails.ts @@ -28,8 +28,6 @@ async function searchEmails({ term, field, sort, order, maxResults }: FormData) sort_fields: processSortField({ sort, order }) } - console.log(requestBody) - return fetch(searchEmailsEndpoint, { method: 'POST', headers: {