fix: load yaml config file

This commit is contained in:
Urko. 2024-05-02 08:46:36 +02:00
parent 8dc7bbc6d4
commit 26ce3260b9
2 changed files with 2 additions and 9 deletions

View File

@ -4,7 +4,7 @@ Tool to automatize your deploy based on file write changes
## Description
After some change is made in our listener file the script placed on path set on `.yaml` variable called **webhook_script_path** will be executed.
After some change is made in our listener file the script placed on path set on `.yaml` configuration falled placed on `./configs/app.yaml` variable called **webhook_script_path** will be executed.
## Context

View File

@ -1,7 +1,6 @@
package main
import (
"flag"
"log"
"os"
"os/signal"
@ -18,13 +17,7 @@ var (
)
func main() {
envFilePath := ""
if os.Getenv("ENV") != "prod" {
flag.StringVar(&envFilePath, ".env path", "/", "provide .env path file as an absolute path")
flag.Parse()
}
config, err := config.LoadConfig(envFilePath)
config, err := config.LoadConfig("./configs/app.yaml")
if err != nil {
panic(err)
}