aws.iam.SamlProvider
Explore with Pulumi AI
Provides an IAM SAML provider.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
import * as std from "@pulumi/std";
const _default = new aws.iam.SamlProvider("default", {
name: "myprovider",
samlMetadataDocument: std.file({
input: "saml-metadata.xml",
}).then(invoke => invoke.result),
});
import pulumi
import pulumi_aws as aws
import pulumi_std as std
default = aws.iam.SamlProvider("default",
name="myprovider",
saml_metadata_document=std.file(input="saml-metadata.xml").result)
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/iam"
"github.com/pulumi/pulumi-std/sdk/go/std"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
invokeFile, err := std.File(ctx, &std.FileArgs{
Input: "saml-metadata.xml",
}, nil)
if err != nil {
return err
}
_, err = iam.NewSamlProvider(ctx, "default", &iam.SamlProviderArgs{
Name: pulumi.String("myprovider"),
SamlMetadataDocument: pulumi.String(invokeFile.Result),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
using Std = Pulumi.Std;
return await Deployment.RunAsync(() =>
{
var @default = new Aws.Iam.SamlProvider("default", new()
{
Name = "myprovider",
SamlMetadataDocument = Std.File.Invoke(new()
{
Input = "saml-metadata.xml",
}).Apply(invoke => invoke.Result),
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.iam.SamlProvider;
import com.pulumi.aws.iam.SamlProviderArgs;
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 default_ = new SamlProvider("default", SamlProviderArgs.builder()
.name("myprovider")
.samlMetadataDocument(StdFunctions.file(FileArgs.builder()
.input("saml-metadata.xml")
.build()).result())
.build());
}
}
resources:
default:
type: aws:iam:SamlProvider
properties:
name: myprovider
samlMetadataDocument:
fn::invoke:
Function: std:file
Arguments:
input: saml-metadata.xml
Return: result
Create SamlProvider Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new SamlProvider(name: string, args: SamlProviderArgs, opts?: CustomResourceOptions);
@overload
def SamlProvider(resource_name: str,
args: SamlProviderArgs,
opts: Optional[ResourceOptions] = None)
@overload
def SamlProvider(resource_name: str,
opts: Optional[ResourceOptions] = None,
saml_metadata_document: Optional[str] = None,
name: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None)
func NewSamlProvider(ctx *Context, name string, args SamlProviderArgs, opts ...ResourceOption) (*SamlProvider, error)
public SamlProvider(string name, SamlProviderArgs args, CustomResourceOptions? opts = null)
public SamlProvider(String name, SamlProviderArgs args)
public SamlProvider(String name, SamlProviderArgs args, CustomResourceOptions options)
type: aws:iam:SamlProvider
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args SamlProviderArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args SamlProviderArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args SamlProviderArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SamlProviderArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args SamlProviderArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var samlProviderResource = new Aws.Iam.SamlProvider("samlProviderResource", new()
{
SamlMetadataDocument = "string",
Name = "string",
Tags =
{
{ "string", "string" },
},
});
example, err := iam.NewSamlProvider(ctx, "samlProviderResource", &iam.SamlProviderArgs{
SamlMetadataDocument: pulumi.String("string"),
Name: pulumi.String("string"),
Tags: pulumi.StringMap{
"string": pulumi.String("string"),
},
})
var samlProviderResource = new SamlProvider("samlProviderResource", SamlProviderArgs.builder()
.samlMetadataDocument("string")
.name("string")
.tags(Map.of("string", "string"))
.build());
saml_provider_resource = aws.iam.SamlProvider("samlProviderResource",
saml_metadata_document="string",
name="string",
tags={
"string": "string",
})
const samlProviderResource = new aws.iam.SamlProvider("samlProviderResource", {
samlMetadataDocument: "string",
name: "string",
tags: {
string: "string",
},
});
type: aws:iam:SamlProvider
properties:
name: string
samlMetadataDocument: string
tags:
string: string
SamlProvider Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The SamlProvider resource accepts the following input properties:
- Saml
Metadata stringDocument - An XML document generated by an identity provider that supports SAML 2.0.
- Name string
- The name of the provider to create.
- Dictionary<string, string>
- Map of resource tags for the IAM SAML provider. .If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
- Saml
Metadata stringDocument - An XML document generated by an identity provider that supports SAML 2.0.
- Name string
- The name of the provider to create.
- map[string]string
- Map of resource tags for the IAM SAML provider. .If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
- saml
Metadata StringDocument - An XML document generated by an identity provider that supports SAML 2.0.
- name String
- The name of the provider to create.
- Map<String,String>
- Map of resource tags for the IAM SAML provider. .If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
- saml
Metadata stringDocument - An XML document generated by an identity provider that supports SAML 2.0.
- name string
- The name of the provider to create.
- {[key: string]: string}
- Map of resource tags for the IAM SAML provider. .If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
- saml_
metadata_ strdocument - An XML document generated by an identity provider that supports SAML 2.0.
- name str
- The name of the provider to create.
- Mapping[str, str]
- Map of resource tags for the IAM SAML provider. .If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
- saml
Metadata StringDocument - An XML document generated by an identity provider that supports SAML 2.0.
- name String
- The name of the provider to create.
- Map<String>
- Map of resource tags for the IAM SAML provider. .If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Outputs
All input properties are implicitly available as output properties. Additionally, the SamlProvider resource produces the following output properties:
- Arn string
- The ARN assigned by AWS for this provider.
- Id string
- The provider-assigned unique ID for this managed resource.
- Dictionary<string, string>
- A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block. - Valid
Until string - The expiration date and time for the SAML provider in RFC1123 format, e.g.,
Mon, 02 Jan 2006 15:04:05 MST
.
- Arn string
- The ARN assigned by AWS for this provider.
- Id string
- The provider-assigned unique ID for this managed resource.
- map[string]string
- A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block. - Valid
Until string - The expiration date and time for the SAML provider in RFC1123 format, e.g.,
Mon, 02 Jan 2006 15:04:05 MST
.
- arn String
- The ARN assigned by AWS for this provider.
- id String
- The provider-assigned unique ID for this managed resource.
- Map<String,String>
- A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block. - valid
Until String - The expiration date and time for the SAML provider in RFC1123 format, e.g.,
Mon, 02 Jan 2006 15:04:05 MST
.
- arn string
- The ARN assigned by AWS for this provider.
- id string
- The provider-assigned unique ID for this managed resource.
- {[key: string]: string}
- A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block. - valid
Until string - The expiration date and time for the SAML provider in RFC1123 format, e.g.,
Mon, 02 Jan 2006 15:04:05 MST
.
- arn str
- The ARN assigned by AWS for this provider.
- id str
- The provider-assigned unique ID for this managed resource.
- Mapping[str, str]
- A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block. - valid_
until str - The expiration date and time for the SAML provider in RFC1123 format, e.g.,
Mon, 02 Jan 2006 15:04:05 MST
.
- arn String
- The ARN assigned by AWS for this provider.
- id String
- The provider-assigned unique ID for this managed resource.
- Map<String>
- A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block. - valid
Until String - The expiration date and time for the SAML provider in RFC1123 format, e.g.,
Mon, 02 Jan 2006 15:04:05 MST
.
Look up Existing SamlProvider Resource
Get an existing SamlProvider 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?: SamlProviderState, opts?: CustomResourceOptions): SamlProvider
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
arn: Optional[str] = None,
name: Optional[str] = None,
saml_metadata_document: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None,
tags_all: Optional[Mapping[str, str]] = None,
valid_until: Optional[str] = None) -> SamlProvider
func GetSamlProvider(ctx *Context, name string, id IDInput, state *SamlProviderState, opts ...ResourceOption) (*SamlProvider, error)
public static SamlProvider Get(string name, Input<string> id, SamlProviderState? state, CustomResourceOptions? opts = null)
public static SamlProvider get(String name, Output<String> id, SamlProviderState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- 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.
- 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.
- Arn string
- The ARN assigned by AWS for this provider.
- Name string
- The name of the provider to create.
- Saml
Metadata stringDocument - An XML document generated by an identity provider that supports SAML 2.0.
- Dictionary<string, string>
- Map of resource tags for the IAM SAML provider. .If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level. - Dictionary<string, string>
- A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block. - Valid
Until string - The expiration date and time for the SAML provider in RFC1123 format, e.g.,
Mon, 02 Jan 2006 15:04:05 MST
.
- Arn string
- The ARN assigned by AWS for this provider.
- Name string
- The name of the provider to create.
- Saml
Metadata stringDocument - An XML document generated by an identity provider that supports SAML 2.0.
- map[string]string
- Map of resource tags for the IAM SAML provider. .If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level. - map[string]string
- A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block. - Valid
Until string - The expiration date and time for the SAML provider in RFC1123 format, e.g.,
Mon, 02 Jan 2006 15:04:05 MST
.
- arn String
- The ARN assigned by AWS for this provider.
- name String
- The name of the provider to create.
- saml
Metadata StringDocument - An XML document generated by an identity provider that supports SAML 2.0.
- Map<String,String>
- Map of resource tags for the IAM SAML provider. .If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level. - Map<String,String>
- A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block. - valid
Until String - The expiration date and time for the SAML provider in RFC1123 format, e.g.,
Mon, 02 Jan 2006 15:04:05 MST
.
- arn string
- The ARN assigned by AWS for this provider.
- name string
- The name of the provider to create.
- saml
Metadata stringDocument - An XML document generated by an identity provider that supports SAML 2.0.
- {[key: string]: string}
- Map of resource tags for the IAM SAML provider. .If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level. - {[key: string]: string}
- A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block. - valid
Until string - The expiration date and time for the SAML provider in RFC1123 format, e.g.,
Mon, 02 Jan 2006 15:04:05 MST
.
- arn str
- The ARN assigned by AWS for this provider.
- name str
- The name of the provider to create.
- saml_
metadata_ strdocument - An XML document generated by an identity provider that supports SAML 2.0.
- Mapping[str, str]
- Map of resource tags for the IAM SAML provider. .If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level. - Mapping[str, str]
- A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block. - valid_
until str - The expiration date and time for the SAML provider in RFC1123 format, e.g.,
Mon, 02 Jan 2006 15:04:05 MST
.
- arn String
- The ARN assigned by AWS for this provider.
- name String
- The name of the provider to create.
- saml
Metadata StringDocument - An XML document generated by an identity provider that supports SAML 2.0.
- Map<String>
- Map of resource tags for the IAM SAML provider. .If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level. - Map<String>
- A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block. - valid
Until String - The expiration date and time for the SAML provider in RFC1123 format, e.g.,
Mon, 02 Jan 2006 15:04:05 MST
.
Import
Using pulumi import
, import IAM SAML Providers using the arn
. For example:
$ pulumi import aws:iam/samlProvider:SamlProvider default arn:aws:iam::123456789012:saml-provider/SAMLADFS
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- AWS Classic pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
aws
Terraform Provider.