import { Ingress } from "kubernetes-models/networking.k8s.io/v1/Ingress"; /** Parameters to create an [[Ingress]] with [[createDeployment]] */ export interface IngressConfig { /** ingress name */ name: string; /** hosts to listen to */ hosts: string[]; /** name of the target service */ serviceName?: string; /** the name of the port of the target service */ servicePortName?: string; /** name of the secret for TLS certificate */ secretName?: string; /** kubernetes annotations */ annotations?: Record; /** is a production ingress */ isProduction: boolean; } /** * * This function will return an [[Ingress]] with some defaults * * The ingress will listen on given `hosts` and redirect to given service * * If the ingress has the `nginx.ingress.kubernetes.io/permanent-redirect` annotation then the `hosts` will be used only for SSL certificate * * ```typescript * import { createIngress } from "@socialgouv/kosko-charts/utils" * * const ingress = createIngress({ * name: "app-ingress", * hosts: ["host1.pouet.fr", "host2.pouet.fr"], * serviceName: "www", * servicePortName: "http" * }); * ``` * @category utils * @return {Deployment} */ export declare const createIngress: (params: IngressConfig) => Ingress; export default createIngress;