Skip to content

"Ruler API Not supported" after upgrading to v1.15.0 #5445

Closed
@friedrichg

Description

@friedrichg

Describe the bug
Grafana 8, 9 and 10 provide an alerting ui to edit alerts and recording rules in cortex.
After upgrading to 0a1c112
Grafana says the Ruler API is not supported and it's not possible to edit recording rules and alerts in cortex anymore

Screenshot 2023-07-07 at 9 28 05 PM

To Reproduce
Steps to reproduce the behavior:

  1. Start Minio
docker run --network=host minio/minio:RELEASE.2021-10-13T00-23-17Z server /shared
  1. Create buckets "blocks" and "ruler" in minio using minio admin interface with minioadmin/minioadmin
  2. Start cortex
$ cat mini.yaml
auth_enabled: false
server:
  http_listen_port: 9009
blocks_storage:
  s3:
    access_key_id: minioadmin
    bucket_name: blocks
    endpoint: 127.0.0.1:9000
    insecure: true
    secret_access_key: minioadmin
ingester:
  lifecycler:
    address: 127.0.0.1
    join_after: 0
    min_ready_duration: 0s
    ring:
      kvstore:
        store: inmemory
      replication_factor: 1
querier:
  store_gateway_addresses: http://127.0.0.1:9009
ruler:
  enable_api: true
ruler_storage:
  s3:
    access_key_id: minioadmin
    bucket_name: ruler
    endpoint: 127.0.0.1:9000
    insecure: true
    secret_access_key: minioadmin
target: query-frontend,querier,ruler,store-gateway,compactor,ingester,distributor
$ docker run --network=host --rm -v $PWD/mini.yaml:/mini.yaml cortexproject/cortex:master-0a1c112 -config.file=/mini.yaml
  1. Start Grafana
docker run --rm --network=host -e GF_LOG_LEVEL=debug grafana/grafana:9.5.5
  1. Open grafana on http://127.0.0.1:3000
  2. Login with admin/admin
  3. Add Prometheus Datasource to grafana with url http://127.0.0.1:9009/prometheus
  4. Click Save & Test

Expected behavior
Ruler API should be enabled with Cortex v1.15.0
After clicking Save & Test it should say:

Screenshot 2023-07-07 at 10 03 27 PM

As it says when repeating the steps using the previous commit
b1cd7b2

docker run --network=host --rm -v $PWD/mini.yaml:/mini.yaml cortexproject/cortex:master-b1cd7b2 -config.file=/mini.yaml

Additional Context
This used to return 404:

GET path=/api/datasources/proxy/uid/b98430e5-c3bc-4be3-a3ed-22e908c01b82/api/v1/status/buildinfo status=404 remote_addr=[::1] time_ms=6 duration=6.483347ms size=19 referer=http://127.0.0.1:3000/datasources/edit/b98430e5-c3bc-4be3-a3ed-22e908c01b82 handler=/api/datasources/proxy/uid/:uid/*

Metadata

Metadata

Assignees

No one assigned

    Labels

    component/rulesBits & bobs todo with rules and alerts: the ruler, config service etc.type/bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions