some fixes for docker and migrations
This commit is contained in:
@@ -8,6 +8,7 @@ import (
|
||||
"io"
|
||||
"log/slog"
|
||||
"net/http"
|
||||
"os"
|
||||
"time"
|
||||
|
||||
"github.com/cenkalti/backoff/v5"
|
||||
@@ -42,7 +43,7 @@ func (s *Service) GetWeatherByCity(ctx context.Context, params GetMeteoData) (Me
|
||||
toDate := fromDate.AddDate(0, 0, params.Days-1)
|
||||
|
||||
operation := func() (*http.Response, error) {
|
||||
url := fmt.Sprintf("http://localhost:8080/data?city=%s&from=%s&to=%s",
|
||||
url := fmt.Sprintf("%s/data?city=%s&from=%s&to=%s", os.Getenv("URL_SERVICE_A"),
|
||||
params.Location, params.Date, toDate.Format("2006-01-02"))
|
||||
|
||||
slog.Info("url", "url", url)
|
||||
|
||||
Reference in New Issue
Block a user