diff --git a/infrastructure/remote_http/ai-api-impl.go b/infrastructure/remote_http/ai-api-impl.go index a08d953..b9e6bc8 100644 --- a/infrastructure/remote_http/ai-api-impl.go +++ b/infrastructure/remote_http/ai-api-impl.go @@ -14,7 +14,7 @@ type aiApiImpl struct { func (aiApiImpl) Completions(ctx context.Context, prompt, groupId string) (*dto.AiRes, error) { logger := utils.NewLog("") - url := "https://ai-service.mylomen.com/text/v3/completions" + url := "http://ai-service.service.consul:8080/text/v3/completions" var aiResult Result[dto.AiRes] resp, err := httpClient.R(). diff --git a/main.go b/main.go index 69f6ca0..bbab86e 100644 --- a/main.go +++ b/main.go @@ -44,7 +44,7 @@ func main() { //健康检测 e.GET("/health", func(c echo.Context) error { return c.JSON(http.StatusOK, "ok") }) - e.GET("/name", func(c echo.Context) error { return c.JSON(http.StatusOK, "wx-server") }) + e.GET("/name", func(c echo.Context) error { return c.JSON(http.StatusOK, "ai-gateway") }) e.GET("/v1/subscribeEmail", func(c echo.Context) error { return c.JSON(http.StatusOK, "ok") }) e.GET("/v1/unsubscribeEmail", func(c echo.Context) error { return c.JSON(http.StatusOK, "ok") }) e.GET("/v1/subscribeTopic", func(c echo.Context) error { return c.JSON(http.StatusOK, "ok") }) diff --git a/nomad-job-test.tpl.hcl b/nomad-job-test.tpl.hcl index 268466b..68c243a 100644 --- a/nomad-job-test.tpl.hcl +++ b/nomad-job-test.tpl.hcl @@ -21,7 +21,7 @@ job "${APP_NAME}-${CI_COMMIT_BRANCH}-job" { env = { "API_ENV" : "prod" - "ST_CONSUL_datacenter" = "dj01" + "ST_CONSUL_datacenter" = "sh01" "APP_NAME" = "${APP_NAME}" "CI_COMMIT_BRANCH" = "${CI_COMMIT_BRANCH}"