()
| 548 | } |
| 549 | |
| 550 | func namespace() (string, error) { |
| 551 | ns, err := os.ReadFile("/var/run/secrets/kubernetes.io/serviceaccount/namespace") |
| 552 | if err != nil { |
| 553 | return "", fmt.Errorf("failed to read namespace from service account: %w", err) |
| 554 | } |
| 555 | return string(ns), nil |
| 556 | } |
| 557 | |
| 558 | func getRedisearchClient(opts *redis.Options, index string) *redisearch.Client { |
| 559 | pool := &redigoredis.Pool{Dial: func() (redigoredis.Conn, error) { |