apiVersion: networking.k8s.io/v1 kind: Ingress metadata: name: swagger-ui namespace: cicd annotations: nginx.ingress.kubernetes.io/enable-cors: "true" nginx.ingress.kubernetes.io/cors-allow-origin: "*" nginx.ingress.kubernetes.io/proxy-cache: "true" nginx.ingress.kubernetes.io/proxy-cache-path: "/tmp/nginx-cache" nginx.ingress.kubernetes.io/proxy-cache-methods: "GET,HEAD,POST" nginx.ingress.kubernetes.io/proxy-cache-min_uses: "1" nginx.ingress.kubernetes.io/proxy-cache-lock: "on" nginx.ingress.kubernetes.io/proxy-cache-valid: "10m" nginx.ingress.kubernetes.io/proxy-cache-max-size: "100m" spec: rules: - host: swagger-ui.cestong.com.cn http: paths: - path: / pathType: Prefix backend: service: name: swagger-ui port: number: 80 ingressClassName: nginx