AccessIdentityProvider

class AccessIdentityProvider : KotlinCustomResource

Provides a Cloudflare Access Identity Provider resource. Identity Providers are used as an authentication or authorisation source within Access.

It's required that an account_id or zone_id is provided and in most cases using either is fine. However, if you're using a scoped access token, you must provide the argument that matches the token's scope. For example, an access token that is scoped to the "example.com" zone needs to use the zone_id argument.

Example Usage

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.cloudflare.AccessIdentityProvider;
import com.pulumi.cloudflare.AccessIdentityProviderArgs;
import com.pulumi.cloudflare.inputs.AccessIdentityProviderConfigArgs;
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 pinLogin = new AccessIdentityProvider("pinLogin", AccessIdentityProviderArgs.builder()
.accountId("f037e56e89293a057740de681ac9abbe")
.name("PIN login")
.type("onetimepin")
.build());
var githubOauth = new AccessIdentityProvider("githubOauth", AccessIdentityProviderArgs.builder()
.accountId("f037e56e89293a057740de681ac9abbe")
.configs(AccessIdentityProviderConfigArgs.builder()
.clientId("example")
.clientSecret("secret_key")
.build())
.name("GitHub OAuth")
.type("github")
.build());
var jumpcloudSaml = new AccessIdentityProvider("jumpcloudSaml", AccessIdentityProviderArgs.builder()
.accountId("f037e56e89293a057740de681ac9abbe")
.configs(AccessIdentityProviderConfigArgs.builder()
.attributes(
"email",
"username")
.idpPublicCert("""
MIIDpDCCAoygAwIBAgIGAV2ka+55MA0GCSqGSIb3DQEBCwUAMIGSMQswCQ...GF/Q2/MHadws97cZg
uTnQyuOqPuHbnN83d/2l1NSYKCbHt24o
""")
.issuerUrl("jumpcloud")
.signRequest(false)
.ssoTargetUrl("https://sso.myexample.jumpcloud.com/saml2/cloudflareaccess")
.build())
.name("JumpCloud SAML")
.type("saml")
.build());
var okta = new AccessIdentityProvider("okta", AccessIdentityProviderArgs.builder()
.accountId("f037e56e89293a057740de681ac9abbe")
.configs(AccessIdentityProviderConfigArgs.builder()
.apiToken("okta_api_token")
.clientId("example")
.clientSecret("secret_key")
.oktaAccount("https://example.com")
.build())
.name("Okta")
.type("okta")
.build());
}
}

Import

$ pulumi import cloudflare:index/accessIdentityProvider:AccessIdentityProvider example <account_id>/<identity_provider_id>

Properties

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

The account identifier to target for the resource. Conflicts with zone_id. Modifying this attribute will force creation of a new resource.

Link copied to clipboard

Provider configuration from the developer documentation.

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

Friendly name of the Access Identity Provider configuration.

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

The provider type to use. Available values: centrify, facebook, google-apps, oidc, github, google, saml, linkedin, azureAD, okta, onetimepin, onelogin, yandex.

Link copied to clipboard
val urn: Output<String>
Link copied to clipboard
val zoneId: Output<String>?

The zone identifier to target for the resource. Conflicts with account_id. Modifying this attribute will force creation of a new resource.