<@ULVA73B9P> I deployed the prefect-server on kube...
# ask-marvin
n
@Marvin I deployed the prefect-server on kubernetes with helm chart, ingress is set in the values. When I access the url I can see the dashboard and is it all well but when I got to prefect.***/api it goes to 404 not found.
m
thought for 473.4 seconds
Thanks for the details. A 404 at
/api
is actually expected with Prefect Server (Prefect 3.x). There isn’t a “root” handler at
/api
itself. Instead, specific API endpoints live under
/api/*
. Quick checks you can run: - Health check (should return 200):
Copy code
curl -i <https://prefect.yourdomain.com/api/health>
- Interactive API docs (Swagger UI):
Copy code
<https://prefect.yourdomain.com/docs>
If
/api/health
also returns 404, that points to an ingress routing/rewriting issue (e.g., a rewrite-target stripping
/api
). In that case: - Ensure you’re using
pathType: Prefix
and you’re not rewriting the path. - For NGINX, avoid
<http://nginx.ingress.kubernetes.io/rewrite-target|nginx.ingress.kubernetes.io/rewrite-target>
unless you know you need it. Example Helm values snippet that typically works without rewrites:
Copy code
ingress:
  enabled: true
  className: nginx
  annotations: {}
  hosts:
    - host: <http://prefect.example.com|prefect.example.com>
      paths:
        - path: /
          pathType: Prefix
  tls:
    - hosts:
        - <http://prefect.example.com|prefect.example.com>
      secretName: prefect-tls
References: - Prefect Helm chart notes: Server Helm (Prefect 3) - Health endpoint docs: /api/health If you share: - Your ingress controller (e.g., NGINX, Traefik) - The relevant ingress/values.yaml section - The result of hitting
/api/health
…I can pinpoint whether it’s just the expected 404 at
/api
or a path rewrite issue.