1. Packages
  2. Google Cloud (GCP) Classic
  3. API Docs
  4. compute
  5. getSSLPolicy
Google Cloud v8.26.0 published on Thursday, Apr 10, 2025 by Pulumi

gcp.compute.getSSLPolicy

Explore with Pulumi AI

Google Cloud v8.26.0 published on Thursday, Apr 10, 2025 by Pulumi

Gets an SSL Policy within GCE from its name, for use with Target HTTPS and Target SSL Proxies. For more information see the official documentation.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";

const my_ssl_policy = gcp.compute.getSSLPolicy({
    name: "production-ssl-policy",
});
Copy
import pulumi
import pulumi_gcp as gcp

my_ssl_policy = gcp.compute.get_ssl_policy(name="production-ssl-policy")
Copy
package main

import (
	"github.com/pulumi/pulumi-gcp/sdk/v8/go/gcp/compute"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := compute.LookupSSLPolicy(ctx, &compute.LookupSSLPolicyArgs{
			Name: "production-ssl-policy",
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;

return await Deployment.RunAsync(() => 
{
    var my_ssl_policy = Gcp.Compute.GetSSLPolicy.Invoke(new()
    {
        Name = "production-ssl-policy",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.compute.ComputeFunctions;
import com.pulumi.gcp.compute.inputs.GetSSLPolicyArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        final var my-ssl-policy = ComputeFunctions.getSSLPolicy(GetSSLPolicyArgs.builder()
            .name("production-ssl-policy")
            .build());

    }
}
Copy
variables:
  my-ssl-policy:
    fn::invoke:
      function: gcp:compute:getSSLPolicy
      arguments:
        name: production-ssl-policy
Copy

Using getSSLPolicy

Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

function getSSLPolicy(args: GetSSLPolicyArgs, opts?: InvokeOptions): Promise<GetSSLPolicyResult>
function getSSLPolicyOutput(args: GetSSLPolicyOutputArgs, opts?: InvokeOptions): Output<GetSSLPolicyResult>
Copy
def get_ssl_policy(name: Optional[str] = None,
                   project: Optional[str] = None,
                   opts: Optional[InvokeOptions] = None) -> GetSSLPolicyResult
def get_ssl_policy_output(name: Optional[pulumi.Input[str]] = None,
                   project: Optional[pulumi.Input[str]] = None,
                   opts: Optional[InvokeOptions] = None) -> Output[GetSSLPolicyResult]
Copy
func LookupSSLPolicy(ctx *Context, args *LookupSSLPolicyArgs, opts ...InvokeOption) (*LookupSSLPolicyResult, error)
func LookupSSLPolicyOutput(ctx *Context, args *LookupSSLPolicyOutputArgs, opts ...InvokeOption) LookupSSLPolicyResultOutput
Copy

> Note: This function is named LookupSSLPolicy in the Go SDK.

public static class GetSSLPolicy 
{
    public static Task<GetSSLPolicyResult> InvokeAsync(GetSSLPolicyArgs args, InvokeOptions? opts = null)
    public static Output<GetSSLPolicyResult> Invoke(GetSSLPolicyInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetSSLPolicyResult> getSSLPolicy(GetSSLPolicyArgs args, InvokeOptions options)
public static Output<GetSSLPolicyResult> getSSLPolicy(GetSSLPolicyArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: gcp:compute/getSSLPolicy:getSSLPolicy
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

Name This property is required. string
The name of the SSL Policy.


Project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
Name This property is required. string
The name of the SSL Policy.


Project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
name This property is required. String
The name of the SSL Policy.


project String
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
name This property is required. string
The name of the SSL Policy.


project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
name This property is required. str
The name of the SSL Policy.


project str
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
name This property is required. String
The name of the SSL Policy.


project String
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.

getSSLPolicy Result

The following output properties are available:

CreationTimestamp string
CustomFeatures List<string>
If the profile is CUSTOM, these are the custom encryption ciphers supported by the profile. If the profile is not CUSTOM, this attribute will be empty.
Description string
Description of this SSL Policy.
EnabledFeatures List<string>
The set of enabled encryption ciphers as a result of the policy config
Fingerprint string
Fingerprint of this resource.
Id string
The provider-assigned unique ID for this managed resource.
MinTlsVersion string
The minimum supported TLS version of this policy.
Name string
Profile string
The Google-curated or custom profile used by this policy.
SelfLink string
The URI of the created resource.
Project string
CreationTimestamp string
CustomFeatures []string
If the profile is CUSTOM, these are the custom encryption ciphers supported by the profile. If the profile is not CUSTOM, this attribute will be empty.
Description string
Description of this SSL Policy.
EnabledFeatures []string
The set of enabled encryption ciphers as a result of the policy config
Fingerprint string
Fingerprint of this resource.
Id string
The provider-assigned unique ID for this managed resource.
MinTlsVersion string
The minimum supported TLS version of this policy.
Name string
Profile string
The Google-curated or custom profile used by this policy.
SelfLink string
The URI of the created resource.
Project string
creationTimestamp String
customFeatures List<String>
If the profile is CUSTOM, these are the custom encryption ciphers supported by the profile. If the profile is not CUSTOM, this attribute will be empty.
description String
Description of this SSL Policy.
enabledFeatures List<String>
The set of enabled encryption ciphers as a result of the policy config
fingerprint String
Fingerprint of this resource.
id String
The provider-assigned unique ID for this managed resource.
minTlsVersion String
The minimum supported TLS version of this policy.
name String
profile String
The Google-curated or custom profile used by this policy.
selfLink String
The URI of the created resource.
project String
creationTimestamp string
customFeatures string[]
If the profile is CUSTOM, these are the custom encryption ciphers supported by the profile. If the profile is not CUSTOM, this attribute will be empty.
description string
Description of this SSL Policy.
enabledFeatures string[]
The set of enabled encryption ciphers as a result of the policy config
fingerprint string
Fingerprint of this resource.
id string
The provider-assigned unique ID for this managed resource.
minTlsVersion string
The minimum supported TLS version of this policy.
name string
profile string
The Google-curated or custom profile used by this policy.
selfLink string
The URI of the created resource.
project string
creation_timestamp str
custom_features Sequence[str]
If the profile is CUSTOM, these are the custom encryption ciphers supported by the profile. If the profile is not CUSTOM, this attribute will be empty.
description str
Description of this SSL Policy.
enabled_features Sequence[str]
The set of enabled encryption ciphers as a result of the policy config
fingerprint str
Fingerprint of this resource.
id str
The provider-assigned unique ID for this managed resource.
min_tls_version str
The minimum supported TLS version of this policy.
name str
profile str
The Google-curated or custom profile used by this policy.
self_link str
The URI of the created resource.
project str
creationTimestamp String
customFeatures List<String>
If the profile is CUSTOM, these are the custom encryption ciphers supported by the profile. If the profile is not CUSTOM, this attribute will be empty.
description String
Description of this SSL Policy.
enabledFeatures List<String>
The set of enabled encryption ciphers as a result of the policy config
fingerprint String
Fingerprint of this resource.
id String
The provider-assigned unique ID for this managed resource.
minTlsVersion String
The minimum supported TLS version of this policy.
name String
profile String
The Google-curated or custom profile used by this policy.
selfLink String
The URI of the created resource.
project String

Package Details

Repository
Google Cloud (GCP) Classic pulumi/pulumi-gcp
License
Apache-2.0
Notes
This Pulumi package is based on the google-beta Terraform Provider.
Google Cloud v8.26.0 published on Thursday, Apr 10, 2025 by Pulumi