Ready to level-up your engineering skills? Join a Pulumi Workshop. Register Now

AuthenticatedOriginPullsCertificate

Provides a Cloudflare Authenticated Origin Pulls certificate resource. An uploaded client certificate is required to use Per-Zone or Per-Hostname Authenticated Origin Pulls.

Example Usage

using Pulumi;
using Cloudflare = Pulumi.Cloudflare;

class MyStack : Stack
{
    public MyStack()
    {
        // Per-Zone Authenticated Origin Pulls certificate
        var myPerZoneAopCert = new Cloudflare.AuthenticatedOriginPullsCertificate("myPerZoneAopCert", new Cloudflare.AuthenticatedOriginPullsCertificateArgs
        {
            Certificate = "-----INSERT CERTIFICATE-----",
            PrivateKey = "-----INSERT PRIVATE KEY-----",
            Type = "per-zone",
            ZoneId = @var.Cloudflare_zone_id,
        });
        // Per-Hostname Authenticated Origin Pulls certificate
        var myPerHostnameAopCert = new Cloudflare.AuthenticatedOriginPullsCertificate("myPerHostnameAopCert", new Cloudflare.AuthenticatedOriginPullsCertificateArgs
        {
            Certificate = "-----INSERT CERTIFICATE-----",
            PrivateKey = "-----INSERT PRIVATE KEY-----",
            Type = "per-hostname",
            ZoneId = @var.Cloudflare_zone_id,
        });
    }

}
package main

import (
    "github.com/pulumi/pulumi-cloudflare/sdk/v2/go/cloudflare"
    "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)

func main() {
    pulumi.Run(func(ctx *pulumi.Context) error {
        _, err := cloudflare.NewAuthenticatedOriginPullsCertificate(ctx, "myPerZoneAopCert", &cloudflare.AuthenticatedOriginPullsCertificateArgs{
            Certificate: pulumi.String("-----INSERT CERTIFICATE-----"),
            PrivateKey:  pulumi.String("-----INSERT PRIVATE KEY-----"),
            Type:        pulumi.String("per-zone"),
            ZoneId:      pulumi.Any(_var.Cloudflare_zone_id),
        })
        if err != nil {
            return err
        }
        _, err = cloudflare.NewAuthenticatedOriginPullsCertificate(ctx, "myPerHostnameAopCert", &cloudflare.AuthenticatedOriginPullsCertificateArgs{
            Certificate: pulumi.String("-----INSERT CERTIFICATE-----"),
            PrivateKey:  pulumi.String("-----INSERT PRIVATE KEY-----"),
            Type:        pulumi.String("per-hostname"),
            ZoneId:      pulumi.Any(_var.Cloudflare_zone_id),
        })
        if err != nil {
            return err
        }
        return nil
    })
}
import pulumi
import pulumi_cloudflare as cloudflare

# Per-Zone Authenticated Origin Pulls certificate
my_per_zone_aop_cert = cloudflare.AuthenticatedOriginPullsCertificate("myPerZoneAopCert",
    certificate="-----INSERT CERTIFICATE-----",
    private_key="-----INSERT PRIVATE KEY-----",
    type="per-zone",
    zone_id=var["cloudflare_zone_id"])
# Per-Hostname Authenticated Origin Pulls certificate
my_per_hostname_aop_cert = cloudflare.AuthenticatedOriginPullsCertificate("myPerHostnameAopCert",
    certificate="-----INSERT CERTIFICATE-----",
    private_key="-----INSERT PRIVATE KEY-----",
    type="per-hostname",
    zone_id=var["cloudflare_zone_id"])
import * as pulumi from "@pulumi/pulumi";
import * as cloudflare from "@pulumi/cloudflare";

// Per-Zone Authenticated Origin Pulls certificate
const myPerZoneAopCert = new cloudflare.AuthenticatedOriginPullsCertificate("my_per_zone_aop_cert", {
    certificate: "-----INSERT CERTIFICATE-----",
    privateKey: "-----INSERT PRIVATE KEY-----",
    type: "per-zone",
    zoneId: var_cloudflare_zone_id,
});
// Per-Hostname Authenticated Origin Pulls certificate
const myPerHostnameAopCert = new cloudflare.AuthenticatedOriginPullsCertificate("my_per_hostname_aop_cert", {
    certificate: "-----INSERT CERTIFICATE-----",
    privateKey: "-----INSERT PRIVATE KEY-----",
    type: "per-hostname",
    zoneId: var_cloudflare_zone_id,
});

Create a AuthenticatedOriginPullsCertificate Resource

new AuthenticatedOriginPullsCertificate(name: string, args: AuthenticatedOriginPullsCertificateArgs, opts?: CustomResourceOptions);
def AuthenticatedOriginPullsCertificate(resource_name: str, opts: Optional[ResourceOptions] = None, certificate: Optional[str] = None, private_key: Optional[str] = None, type: Optional[str] = None, zone_id: Optional[str] = None)
func NewAuthenticatedOriginPullsCertificate(ctx *Context, name string, args AuthenticatedOriginPullsCertificateArgs, opts ...ResourceOption) (*AuthenticatedOriginPullsCertificate, error)
public AuthenticatedOriginPullsCertificate(string name, AuthenticatedOriginPullsCertificateArgs args, CustomResourceOptions? opts = null)
name string
The unique name of the resource.
args AuthenticatedOriginPullsCertificateArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
opts ResourceOptions
A bag of options that control this resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args AuthenticatedOriginPullsCertificateArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args AuthenticatedOriginPullsCertificateArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.

AuthenticatedOriginPullsCertificate Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.

Inputs

The AuthenticatedOriginPullsCertificate resource accepts the following input properties:

Certificate string

The public client certificate.

PrivateKey string

The private key of the client certificate.

Type string

The form of Authenticated Origin Pulls to upload the certificate to.

ZoneId string

The zone ID to upload the certificate to.

Certificate string

The public client certificate.

PrivateKey string

The private key of the client certificate.

Type string

The form of Authenticated Origin Pulls to upload the certificate to.

ZoneId string

The zone ID to upload the certificate to.

certificate string

The public client certificate.

privateKey string

The private key of the client certificate.

type string

The form of Authenticated Origin Pulls to upload the certificate to.

zoneId string

The zone ID to upload the certificate to.

certificate str

The public client certificate.

private_key str

The private key of the client certificate.

type str

The form of Authenticated Origin Pulls to upload the certificate to.

zone_id str

The zone ID to upload the certificate to.

Outputs

All input properties are implicitly available as output properties. Additionally, the AuthenticatedOriginPullsCertificate resource produces the following output properties:

ExpiresOn string
Id string
The provider-assigned unique ID for this managed resource.
Issuer string
SerialNumber string
Signature string
Status string
UploadedOn string
ExpiresOn string
Id string
The provider-assigned unique ID for this managed resource.
Issuer string
SerialNumber string
Signature string
Status string
UploadedOn string
expiresOn string
id string
The provider-assigned unique ID for this managed resource.
issuer string
serialNumber string
signature string
status string
uploadedOn string
expires_on str
id str
The provider-assigned unique ID for this managed resource.
issuer str
serial_number str
signature str
status str
uploaded_on str

Look up an Existing AuthenticatedOriginPullsCertificate Resource

Get an existing AuthenticatedOriginPullsCertificate resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: AuthenticatedOriginPullsCertificateState, opts?: CustomResourceOptions): AuthenticatedOriginPullsCertificate
@staticmethod
def get(resource_name: str, id: str, opts: Optional[ResourceOptions] = None, certificate: Optional[str] = None, expires_on: Optional[str] = None, issuer: Optional[str] = None, private_key: Optional[str] = None, serial_number: Optional[str] = None, signature: Optional[str] = None, status: Optional[str] = None, type: Optional[str] = None, uploaded_on: Optional[str] = None, zone_id: Optional[str] = None) -> AuthenticatedOriginPullsCertificate
func GetAuthenticatedOriginPullsCertificate(ctx *Context, name string, id IDInput, state *AuthenticatedOriginPullsCertificateState, opts ...ResourceOption) (*AuthenticatedOriginPullsCertificate, error)
public static AuthenticatedOriginPullsCertificate Get(string name, Input<string> id, AuthenticatedOriginPullsCertificateState? state, CustomResourceOptions? opts = null)
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.

The following state arguments are supported:

Certificate string

The public client certificate.

ExpiresOn string
Issuer string
PrivateKey string

The private key of the client certificate.

SerialNumber string
Signature string
Status string
Type string

The form of Authenticated Origin Pulls to upload the certificate to.

UploadedOn string
ZoneId string

The zone ID to upload the certificate to.

Certificate string

The public client certificate.

ExpiresOn string
Issuer string
PrivateKey string

The private key of the client certificate.

SerialNumber string
Signature string
Status string
Type string

The form of Authenticated Origin Pulls to upload the certificate to.

UploadedOn string
ZoneId string

The zone ID to upload the certificate to.

certificate string

The public client certificate.

expiresOn string
issuer string
privateKey string

The private key of the client certificate.

serialNumber string
signature string
status string
type string

The form of Authenticated Origin Pulls to upload the certificate to.

uploadedOn string
zoneId string

The zone ID to upload the certificate to.

certificate str

The public client certificate.

expires_on str
issuer str
private_key str

The private key of the client certificate.

serial_number str
signature str
status str
type str

The form of Authenticated Origin Pulls to upload the certificate to.

uploaded_on str
zone_id str

The zone ID to upload the certificate to.

Import

Authenticated Origin Pull certificates can be imported using a composite ID formed of the zone ID, the form of Authenticated Origin Pulls, and the certificate ID, e.g. # Import Per-Zone Authenticated Origin Pull certificate

 $ pulumi import cloudflare:index/authenticatedOriginPullsCertificate:AuthenticatedOriginPullsCertificate 2458ce5a-0c35-4c7f-82c7-8e9487d3ff60 023e105f4ecef8ad9ca31a8372d0c353/per-zone/2458ce5a-0c35-4c7f-82c7-8e9487d3ff60

Import Per-Hostname Authenticated Origin Pull certificate

 $ pulumi import cloudflare:index/authenticatedOriginPullsCertificate:AuthenticatedOriginPullsCertificate 2458ce5a-0c35-4c7f-82c7-8e9487d3ff60 023e105f4ecef8ad9ca31a8372d0c353/per-hostname/2458ce5a-0c35-4c7f-82c7-8e9487d3ff60

Package Details

Repository
https://github.com/pulumi/pulumi-cloudflare
License
Apache-2.0
Notes
This Pulumi package is based on the cloudflare Terraform Provider.