@pulumiverse/scaleway
Version:
A Pulumi package for creating and managing Scaleway cloud resources.
146 lines • 5.54 kB
JavaScript
;
// *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
Object.defineProperty(exports, "__esModule", { value: true });
exports.EdgeServicesPipeline = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("./utilities");
/**
* Creates and manages Scaleway Edge Services Pipelines.
*
* ## Example Usage
*
* ### Basic
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as scaleway from "@pulumiverse/scaleway";
*
* const main = new scaleway.EdgeServicesPipeline("main", {
* name: "pipeline-name",
* description: "pipeline description",
* });
* ```
*
* ### Complete pipeline
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as scaleway from "@pulumiverse/scaleway";
*
* const main = new scaleway.EdgeServicesPipeline("main", {
* name: "pipeline-name",
* description: "pipeline description",
* });
* const mainEdgeServicesBackendStage = new scaleway.EdgeServicesBackendStage("main", {
* pipelineId: main.id,
* s3BackendConfig: {
* bucketName: "my-bucket-name",
* bucketRegion: "fr-par",
* },
* });
* const mainEdgeServicesWafStage = new scaleway.EdgeServicesWafStage("main", {
* pipelineId: main.id,
* backendStageId: mainEdgeServicesBackendStage.id,
* mode: "enable",
* paranoiaLevel: 3,
* });
* const mainEdgeServicesRouteStage = new scaleway.EdgeServicesRouteStage("main", {
* pipelineId: main.id,
* wafStageId: mainEdgeServicesWafStage.id,
* rules: [{
* backendStageId: mainEdgeServicesBackendStage.id,
* ruleHttpMatch: {
* methodFilters: [
* "get",
* "post",
* ],
* pathFilter: {
* pathFilterType: "regex",
* value: ".*",
* },
* },
* }],
* });
* const mainEdgeServicesCacheStage = new scaleway.EdgeServicesCacheStage("main", {
* pipelineId: main.id,
* routeStageId: mainEdgeServicesRouteStage.id,
* });
* const mainEdgeServicesTlsStage = new scaleway.EdgeServicesTlsStage("main", {
* pipelineId: main.id,
* cacheStageId: mainEdgeServicesCacheStage.id,
* managedCertificate: true,
* });
* const mainEdgeServicesDnsStage = new scaleway.EdgeServicesDnsStage("main", {
* pipelineId: main.id,
* tlsStageId: mainEdgeServicesTlsStage.id,
* fqdns: ["subdomain.example.com"],
* });
* const mainEdgeServicesHeadStage = new scaleway.EdgeServicesHeadStage("main", {
* pipelineId: main.id,
* headStageId: mainEdgeServicesDnsStage.id,
* });
* ```
*
* ## Import
*
* Pipelines can be imported using the `{id}`, e.g.
*
* bash
*
* ```sh
* $ pulumi import scaleway:index/edgeServicesPipeline:EdgeServicesPipeline basic 11111111-1111-1111-1111-111111111111
* ```
*/
class EdgeServicesPipeline extends pulumi.CustomResource {
/**
* Get an existing EdgeServicesPipeline 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, id, state, opts) {
return new EdgeServicesPipeline(name, state, Object.assign(Object.assign({}, opts), { id: id }));
}
/**
* Returns true if the given object is an instance of EdgeServicesPipeline. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
static isInstance(obj) {
if (obj === undefined || obj === null) {
return false;
}
return obj['__pulumiType'] === EdgeServicesPipeline.__pulumiType;
}
constructor(name, argsOrState, opts) {
let resourceInputs = {};
opts = opts || {};
if (opts.id) {
const state = argsOrState;
resourceInputs["createdAt"] = state ? state.createdAt : undefined;
resourceInputs["description"] = state ? state.description : undefined;
resourceInputs["name"] = state ? state.name : undefined;
resourceInputs["projectId"] = state ? state.projectId : undefined;
resourceInputs["status"] = state ? state.status : undefined;
resourceInputs["updatedAt"] = state ? state.updatedAt : undefined;
}
else {
const args = argsOrState;
resourceInputs["description"] = args ? args.description : undefined;
resourceInputs["name"] = args ? args.name : undefined;
resourceInputs["projectId"] = args ? args.projectId : undefined;
resourceInputs["createdAt"] = undefined /*out*/;
resourceInputs["status"] = undefined /*out*/;
resourceInputs["updatedAt"] = undefined /*out*/;
}
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
super(EdgeServicesPipeline.__pulumiType, name, resourceInputs, opts);
}
}
exports.EdgeServicesPipeline = EdgeServicesPipeline;
/** @internal */
EdgeServicesPipeline.__pulumiType = 'scaleway:index/edgeServicesPipeline:EdgeServicesPipeline';
//# sourceMappingURL=edgeServicesPipeline.js.map