import * as pulumi from "@pulumi/pulumi"; import * as inputs from "./types/input"; import * as outputs from "./types/output"; /** * Creates and manages Scaleway Load Balancer frontends. * * For more information, see the [main documentation](https://www.scaleway.com/en/docs/network/load-balancer/reference-content/configuring-frontends/) or [API documentation](https://www.scaleway.com/en/developers/api/load-balancer/zoned-api/#path-frontends). * * ## Example Usage * * ### Basic * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as scaleway from "@ediri/scaleway"; * * const frontend01 = new scaleway.LbFrontend("frontend01", { * lbId: scaleway_lb.lb01.id, * backendId: scaleway_lb_backend.backend01.id, * inboundPort: 80, * }); * ``` * * ## With ACLs * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as scaleway from "@ediri/scaleway"; * * const frontend01 = new scaleway.LbFrontend("frontend01", { * lbId: scaleway_lb.lb01.id, * backendId: scaleway_lb_backend.backend01.id, * inboundPort: 80, * acls: [ * { * name: "blacklist wellknwon IPs", * action: { * type: "allow", * }, * match: { * ipSubnets: [ * "192.168.0.1", * "192.168.0.2", * "192.168.10.0/24", * ], * }, * }, * { * action: { * type: "deny", * }, * match: { * ipSubnets: ["51.51.51.51"], * httpFilter: "regex", * httpFilterValues: ["^foo*bar$"], * }, * }, * { * action: { * type: "allow", * }, * match: { * httpFilter: "path_begin", * httpFilterValues: [ * "foo", * "bar", * ], * }, * }, * { * action: { * type: "allow", * }, * match: { * httpFilter: "path_begin", * httpFilterValues: ["hi"], * invert: true, * }, * }, * { * action: { * type: "allow", * }, * match: { * httpFilter: "http_header_match", * httpFilterValues: "foo", * httpFilterOption: "bar", * }, * }, * { * action: { * type: "redirect", * redirects: [{ * type: "location", * target: "https://example.com", * code: 307, * }], * }, * match: { * ipSubnets: ["10.0.0.10"], * httpFilter: "path_begin", * httpFilterValues: [ * "foo", * "bar", * ], * }, * }, * ], * }); * ``` * * ## Import * * Load Balancer frontends can be imported using `{zone}/{id}`, e.g. * * bash * * ```sh * $ pulumi import scaleway:index/lbFrontend:LbFrontend frontend01 fr-par-1/11111111-1111-1111-1111-111111111111 * ``` */ export declare class LbFrontend extends pulumi.CustomResource { /** * Get an existing LbFrontend resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input, state?: LbFrontendState, opts?: pulumi.CustomResourceOptions): LbFrontend; /** * Returns true if the given object is an instance of LbFrontend. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is LbFrontend; /** * A list of ACL rules to apply to the Load Balancer frontend. Defined below. */ readonly acls: pulumi.Output; /** * The ID of the Load Balancer backend this frontend is attached to. * * > **Important:** Updates to `lbId` or `backendId` will recreate the frontend. */ readonly backendId: pulumi.Output; /** * (Deprecated, use `certificateIds` instead) First certificate ID used by the frontend. * * @deprecated Please use certificate_ids */ readonly certificateId: pulumi.Output; /** * List of certificate IDs that should be used by the frontend. * * > **Important:** Certificates are not allowed on port 80. */ readonly certificateIds: pulumi.Output; /** * Activates HTTP/3 protocol. */ readonly enableHttp3: pulumi.Output; /** * A boolean to specify whether to use lb_acl. * If `externalAcls` is set to `true`, `acl` can not be set directly in the Load Balancer frontend. */ readonly externalAcls: pulumi.Output; /** * TCP port to listen to on the front side. */ readonly inboundPort: pulumi.Output; /** * The ID of the Load Balancer this frontend is attached to. */ readonly lbId: pulumi.Output; /** * The ACL name. If not provided it will be randomly generated. */ readonly name: pulumi.Output; /** * Maximum inactivity time on the client side. (e.g. `1s`) */ readonly timeoutClient: pulumi.Output; /** * Create a LbFrontend resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: LbFrontendArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering LbFrontend resources. */ export interface LbFrontendState { /** * A list of ACL rules to apply to the Load Balancer frontend. Defined below. */ acls?: pulumi.Input[]>; /** * The ID of the Load Balancer backend this frontend is attached to. * * > **Important:** Updates to `lbId` or `backendId` will recreate the frontend. */ backendId?: pulumi.Input; /** * (Deprecated, use `certificateIds` instead) First certificate ID used by the frontend. * * @deprecated Please use certificate_ids */ certificateId?: pulumi.Input; /** * List of certificate IDs that should be used by the frontend. * * > **Important:** Certificates are not allowed on port 80. */ certificateIds?: pulumi.Input[]>; /** * Activates HTTP/3 protocol. */ enableHttp3?: pulumi.Input; /** * A boolean to specify whether to use lb_acl. * If `externalAcls` is set to `true`, `acl` can not be set directly in the Load Balancer frontend. */ externalAcls?: pulumi.Input; /** * TCP port to listen to on the front side. */ inboundPort?: pulumi.Input; /** * The ID of the Load Balancer this frontend is attached to. */ lbId?: pulumi.Input; /** * The ACL name. If not provided it will be randomly generated. */ name?: pulumi.Input; /** * Maximum inactivity time on the client side. (e.g. `1s`) */ timeoutClient?: pulumi.Input; } /** * The set of arguments for constructing a LbFrontend resource. */ export interface LbFrontendArgs { /** * A list of ACL rules to apply to the Load Balancer frontend. Defined below. */ acls?: pulumi.Input[]>; /** * The ID of the Load Balancer backend this frontend is attached to. * * > **Important:** Updates to `lbId` or `backendId` will recreate the frontend. */ backendId: pulumi.Input; /** * List of certificate IDs that should be used by the frontend. * * > **Important:** Certificates are not allowed on port 80. */ certificateIds?: pulumi.Input[]>; /** * Activates HTTP/3 protocol. */ enableHttp3?: pulumi.Input; /** * A boolean to specify whether to use lb_acl. * If `externalAcls` is set to `true`, `acl` can not be set directly in the Load Balancer frontend. */ externalAcls?: pulumi.Input; /** * TCP port to listen to on the front side. */ inboundPort: pulumi.Input; /** * The ID of the Load Balancer this frontend is attached to. */ lbId: pulumi.Input; /** * The ACL name. If not provided it will be randomly generated. */ name?: pulumi.Input; /** * Maximum inactivity time on the client side. (e.g. `1s`) */ timeoutClient?: pulumi.Input; }