Certificate

class Certificate : KotlinCustomResource

Creates and manages an AWS IoT certificate.

Example Usage

With CSR

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.iot.Certificate;
import com.pulumi.aws.iot.CertificateArgs;
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) {
var cert = new Certificate("cert", CertificateArgs.builder()
.csr(Files.readString(Paths.get("/my/csr.pem")))
.active(true)
.build());
}
}

Without CSR

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.iot.Certificate;
import com.pulumi.aws.iot.CertificateArgs;
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) {
var cert = new Certificate("cert", CertificateArgs.builder()
.active(true)
.build());
}
}

From existing certificate without a CA

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.iot.Certificate;
import com.pulumi.aws.iot.CertificateArgs;
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) {
var cert = new Certificate("cert", CertificateArgs.builder()
.certificatePem(Files.readString(Paths.get("/my/cert.pem")))
.active(true)
.build());
}
}

Properties

Link copied to clipboard
val active: Output<Boolean>

Boolean flag to indicate if the certificate should be active

Link copied to clipboard
val arn: Output<String>

The ARN of the created certificate.

Link copied to clipboard
val caPem: Output<String>?

The CA certificate for the certificate to be registered. If this is set, the CA needs to be registered with AWS IoT beforehand.

Link copied to clipboard
val certificatePem: Output<String>

The certificate to be registered. If ca_pem is unspecified, review RegisterCertificateWithoutCA. If ca_pem is specified, review RegisterCertificate for more information on registering a certificate.

Link copied to clipboard
val csr: Output<String>?

The certificate signing request. Review CreateCertificateFromCsr for more information on generating a certificate from a certificate signing request (CSR). If none is specified both the certificate and keys will be generated, review CreateKeysAndCertificate for more information on generating keys and a certificate.

Link copied to clipboard
val id: Output<String>
Link copied to clipboard
val privateKey: Output<String>

When neither CSR nor certificate is provided, the private key.

Link copied to clipboard
val publicKey: Output<String>

When neither CSR nor certificate is provided, the public key.

Link copied to clipboard
val pulumiChildResources: Set<KotlinResource>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val urn: Output<String>