UNPKG

@pulumi/scm

Version:

A Pulumi package for managing resources on Strata Cloud Manager.. Based on terraform-provider-scm: version v0.2.1

293 lines (292 loc) 8.13 kB
import * as pulumi from "@pulumi/pulumi"; import * as inputs from "./types/input"; import * as outputs from "./types/output"; /** * ServiceConnection resource * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as scm from "@pulumi/scm"; * * const config = new pulumi.Config(); * // The folder scope for the SCM resource (e.g., 'Shared', 'Predefined', or a specific folder name). * const folderScope = config.get("folderScope") || "Service Connections"; * //# 1. Define the IKE Crypto Profile (IKE Phase 1) * // Note: The resource name is plural: "scm_ike_crypto_profile" * const example = new scm.IkeCryptoProfile("example", { * name: "example-ike-crypto", * folder: folderScope, * hashes: ["sha256"], * dhGroups: ["group14"], * encryptions: ["aes-256-cbc"], * }); * //# 2. Define the IPsec Crypto Profile (IKE Phase 2) * // Note: The resource name is plural and nested blocks now use an equals sign (=). * const exampleIpsecCryptoProfile = new scm.IpsecCryptoProfile("example", { * name: "panw-IPSec-Crypto", * folder: folderScope, * esp: { * encryptions: ["aes-256-gcm"], * authentications: ["sha256"], * }, * dhGroup: "group14", * lifetime: { * hours: 8, * }, * }); * //# 3. Define the IKE Gateway * // Note: The resource name is plural and nested blocks now use an equals sign (=). * const exampleIkeGateway = new scm.IkeGateway("example", { * name: "example-gateway", * folder: folderScope, * peerAddress: { * ip: "1.1.1.1", * }, * authentication: { * preSharedKey: { * key: "secret", * }, * }, * protocol: { * ikev1: { * ikeCryptoProfile: example.name, * }, * }, * }); * //# 4. Define the IPsec Tunnel * // Note: Nested 'auto_key' block uses an equals sign (=). * const exampleIpsecTunnel = new scm.IpsecTunnel("example", { * name: "example-tunnel", * folder: folderScope, * tunnelInterface: "tunnel", * antiReplay: true, * copyTos: false, * enableGreEncapsulation: false, * autoKey: { * ikeGateways: [{ * name: exampleIkeGateway.name, * }], * ipsecCryptoProfile: exampleIpsecCryptoProfile.name, * }, * }, { * dependsOn: [exampleIkeGateway], * }); * const siteAVpnSc = new scm.ServiceConnection("site_a_vpn_sc", { * name: "creating_a_service_connection", * region: "us-west-1", * ipsecTunnel: exampleIpsecTunnel.name, * subnets: [ * "10.1.0.0/16", * "172.16.0.0/24", * ], * sourceNat: true, * }); * ``` */ export declare class ServiceConnection extends pulumi.CustomResource { /** * Get an existing ServiceConnection 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<pulumi.ID>, state?: ServiceConnectionState, opts?: pulumi.CustomResourceOptions): ServiceConnection; /** * Returns true if the given object is an instance of ServiceConnection. 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 ServiceConnection; /** * Backup s c */ readonly backupSc: pulumi.Output<string | undefined>; /** * Bgp peer */ readonly bgpPeer: pulumi.Output<outputs.ServiceConnectionBgpPeer | undefined>; /** * Map of sensitive values returned from the API. */ readonly encryptedValues: pulumi.Output<{ [key: string]: string; }>; /** * Ipsec tunnel */ readonly ipsecTunnel: pulumi.Output<string>; /** * The name of the service connection */ readonly name: pulumi.Output<string>; /** * Nat pool */ readonly natPool: pulumi.Output<string | undefined>; /** * No export community */ readonly noExportCommunity: pulumi.Output<string | undefined>; /** * Onboarding type */ readonly onboardingType: pulumi.Output<string>; /** * Protocol */ readonly protocol: pulumi.Output<outputs.ServiceConnectionProtocol | undefined>; /** * Qos */ readonly qos: pulumi.Output<outputs.ServiceConnectionQos | undefined>; /** * Region */ readonly region: pulumi.Output<string>; /** * Secondary ipsec tunnel */ readonly secondaryIpsecTunnel: pulumi.Output<string | undefined>; /** * Source nat */ readonly sourceNat: pulumi.Output<boolean | undefined>; /** * Subnets */ readonly subnets: pulumi.Output<string[] | undefined>; readonly tfid: pulumi.Output<string>; /** * Create a ServiceConnection 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: ServiceConnectionArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering ServiceConnection resources. */ export interface ServiceConnectionState { /** * Backup s c */ backupSc?: pulumi.Input<string>; /** * Bgp peer */ bgpPeer?: pulumi.Input<inputs.ServiceConnectionBgpPeer>; /** * Map of sensitive values returned from the API. */ encryptedValues?: pulumi.Input<{ [key: string]: pulumi.Input<string>; }>; /** * Ipsec tunnel */ ipsecTunnel?: pulumi.Input<string>; /** * The name of the service connection */ name?: pulumi.Input<string>; /** * Nat pool */ natPool?: pulumi.Input<string>; /** * No export community */ noExportCommunity?: pulumi.Input<string>; /** * Onboarding type */ onboardingType?: pulumi.Input<string>; /** * Protocol */ protocol?: pulumi.Input<inputs.ServiceConnectionProtocol>; /** * Qos */ qos?: pulumi.Input<inputs.ServiceConnectionQos>; /** * Region */ region?: pulumi.Input<string>; /** * Secondary ipsec tunnel */ secondaryIpsecTunnel?: pulumi.Input<string>; /** * Source nat */ sourceNat?: pulumi.Input<boolean>; /** * Subnets */ subnets?: pulumi.Input<pulumi.Input<string>[]>; tfid?: pulumi.Input<string>; } /** * The set of arguments for constructing a ServiceConnection resource. */ export interface ServiceConnectionArgs { /** * Backup s c */ backupSc?: pulumi.Input<string>; /** * Bgp peer */ bgpPeer?: pulumi.Input<inputs.ServiceConnectionBgpPeer>; /** * Ipsec tunnel */ ipsecTunnel: pulumi.Input<string>; /** * The name of the service connection */ name?: pulumi.Input<string>; /** * Nat pool */ natPool?: pulumi.Input<string>; /** * No export community */ noExportCommunity?: pulumi.Input<string>; /** * Onboarding type */ onboardingType?: pulumi.Input<string>; /** * Protocol */ protocol?: pulumi.Input<inputs.ServiceConnectionProtocol>; /** * Qos */ qos?: pulumi.Input<inputs.ServiceConnectionQos>; /** * Region */ region: pulumi.Input<string>; /** * Secondary ipsec tunnel */ secondaryIpsecTunnel?: pulumi.Input<string>; /** * Source nat */ sourceNat?: pulumi.Input<boolean>; /** * Subnets */ subnets?: pulumi.Input<pulumi.Input<string>[]>; }