alicloud.cloudsso.ScimServerCredential
Explore with Pulumi AI
Provides a Cloud SSO SCIM Server Credential resource.
For information about Cloud SSO SCIM Server Credential and how to use it, see What is Cloud SSO SCIM Server Credential.
NOTE: Available since v1.138.0.
NOTE: Cloud SSO Only Support
cn-shanghai
Andus-west-1
Region
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const config = new pulumi.Config();
const name = config.get("name") || "terraform-example";
const _default = alicloud.cloudsso.getDirectories({});
const defaultScimServerCredential = new alicloud.cloudsso.ScimServerCredential("default", {
directoryId: _default.then(_default => _default.directories?.[0]?.id),
credentialSecretFile: "./credential_secret_file.txt",
});
import pulumi
import pulumi_alicloud as alicloud
config = pulumi.Config()
name = config.get("name")
if name is None:
name = "terraform-example"
default = alicloud.cloudsso.get_directories()
default_scim_server_credential = alicloud.cloudsso.ScimServerCredential("default",
directory_id=default.directories[0].id,
credential_secret_file="./credential_secret_file.txt")
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/cloudsso"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
cfg := config.New(ctx, "")
name := "terraform-example"
if param := cfg.Get("name"); param != "" {
name = param
}
_default, err := cloudsso.GetDirectories(ctx, &cloudsso.GetDirectoriesArgs{}, nil)
if err != nil {
return err
}
_, err = cloudsso.NewScimServerCredential(ctx, "default", &cloudsso.ScimServerCredentialArgs{
DirectoryId: pulumi.String(_default.Directories[0].Id),
CredentialSecretFile: pulumi.String("./credential_secret_file.txt"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var config = new Config();
var name = config.Get("name") ?? "terraform-example";
var @default = AliCloud.CloudSso.GetDirectories.Invoke();
var defaultScimServerCredential = new AliCloud.CloudSso.ScimServerCredential("default", new()
{
DirectoryId = @default.Apply(@default => @default.Apply(getDirectoriesResult => getDirectoriesResult.Directories[0]?.Id)),
CredentialSecretFile = "./credential_secret_file.txt",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.cloudsso.CloudssoFunctions;
import com.pulumi.alicloud.cloudsso.inputs.GetDirectoriesArgs;
import com.pulumi.alicloud.cloudsso.ScimServerCredential;
import com.pulumi.alicloud.cloudsso.ScimServerCredentialArgs;
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 config = ctx.config();
final var name = config.get("name").orElse("terraform-example");
final var default = CloudssoFunctions.getDirectories(GetDirectoriesArgs.builder()
.build());
var defaultScimServerCredential = new ScimServerCredential("defaultScimServerCredential", ScimServerCredentialArgs.builder()
.directoryId(default_.directories()[0].id())
.credentialSecretFile("./credential_secret_file.txt")
.build());
}
}
configuration:
name:
type: string
default: terraform-example
resources:
defaultScimServerCredential:
type: alicloud:cloudsso:ScimServerCredential
name: default
properties:
directoryId: ${default.directories[0].id}
credentialSecretFile: ./credential_secret_file.txt
variables:
default:
fn::invoke:
function: alicloud:cloudsso:getDirectories
arguments: {}
Create ScimServerCredential Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ScimServerCredential(name: string, args: ScimServerCredentialArgs, opts?: CustomResourceOptions);
@overload
def ScimServerCredential(resource_name: str,
args: ScimServerCredentialArgs,
opts: Optional[ResourceOptions] = None)
@overload
def ScimServerCredential(resource_name: str,
opts: Optional[ResourceOptions] = None,
directory_id: Optional[str] = None,
credential_secret_file: Optional[str] = None,
status: Optional[str] = None)
func NewScimServerCredential(ctx *Context, name string, args ScimServerCredentialArgs, opts ...ResourceOption) (*ScimServerCredential, error)
public ScimServerCredential(string name, ScimServerCredentialArgs args, CustomResourceOptions? opts = null)
public ScimServerCredential(String name, ScimServerCredentialArgs args)
public ScimServerCredential(String name, ScimServerCredentialArgs args, CustomResourceOptions options)
type: alicloud:cloudsso:ScimServerCredential
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 ScimServerCredentialArgs
- 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 ScimServerCredentialArgs
- 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 ScimServerCredentialArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ScimServerCredentialArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ScimServerCredentialArgs
- 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 scimServerCredentialResource = new AliCloud.CloudSso.ScimServerCredential("scimServerCredentialResource", new()
{
DirectoryId = "string",
CredentialSecretFile = "string",
Status = "string",
});
example, err := cloudsso.NewScimServerCredential(ctx, "scimServerCredentialResource", &cloudsso.ScimServerCredentialArgs{
DirectoryId: pulumi.String("string"),
CredentialSecretFile: pulumi.String("string"),
Status: pulumi.String("string"),
})
var scimServerCredentialResource = new ScimServerCredential("scimServerCredentialResource", ScimServerCredentialArgs.builder()
.directoryId("string")
.credentialSecretFile("string")
.status("string")
.build());
scim_server_credential_resource = alicloud.cloudsso.ScimServerCredential("scimServerCredentialResource",
directory_id="string",
credential_secret_file="string",
status="string")
const scimServerCredentialResource = new alicloud.cloudsso.ScimServerCredential("scimServerCredentialResource", {
directoryId: "string",
credentialSecretFile: "string",
status: "string",
});
type: alicloud:cloudsso:ScimServerCredential
properties:
credentialSecretFile: string
directoryId: string
status: string
ScimServerCredential Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The ScimServerCredential resource accepts the following input properties:
- Directory
Id string - The ID of the Directory.
- Credential
Secret stringFile - The name of file that can save Credential ID and Credential Secret. Strongly suggest you to specified it when you creating credential, otherwise, you wouldn't get its secret ever.
- Status string
- The status of the SCIM Server Credential. Valid values:
Enabled
,Disabled
.
- Directory
Id string - The ID of the Directory.
- Credential
Secret stringFile - The name of file that can save Credential ID and Credential Secret. Strongly suggest you to specified it when you creating credential, otherwise, you wouldn't get its secret ever.
- Status string
- The status of the SCIM Server Credential. Valid values:
Enabled
,Disabled
.
- directory
Id String - The ID of the Directory.
- credential
Secret StringFile - The name of file that can save Credential ID and Credential Secret. Strongly suggest you to specified it when you creating credential, otherwise, you wouldn't get its secret ever.
- status String
- The status of the SCIM Server Credential. Valid values:
Enabled
,Disabled
.
- directory
Id string - The ID of the Directory.
- credential
Secret stringFile - The name of file that can save Credential ID and Credential Secret. Strongly suggest you to specified it when you creating credential, otherwise, you wouldn't get its secret ever.
- status string
- The status of the SCIM Server Credential. Valid values:
Enabled
,Disabled
.
- directory_
id str - The ID of the Directory.
- credential_
secret_ strfile - The name of file that can save Credential ID and Credential Secret. Strongly suggest you to specified it when you creating credential, otherwise, you wouldn't get its secret ever.
- status str
- The status of the SCIM Server Credential. Valid values:
Enabled
,Disabled
.
- directory
Id String - The ID of the Directory.
- credential
Secret StringFile - The name of file that can save Credential ID and Credential Secret. Strongly suggest you to specified it when you creating credential, otherwise, you wouldn't get its secret ever.
- status String
- The status of the SCIM Server Credential. Valid values:
Enabled
,Disabled
.
Outputs
All input properties are implicitly available as output properties. Additionally, the ScimServerCredential resource produces the following output properties:
- Create
Time string - (Available since v1.245.0) The time when the SCIM credential was created.
- Credential
Id string - The ID of the SCIM credential.
- Credential
Type string - (Available since v1.245.0) The type of the SCIM credential.
- Expire
Time string - (Available since v1.245.0) The time when the SCIM credential expires.
- Id string
- The provider-assigned unique ID for this managed resource.
- Create
Time string - (Available since v1.245.0) The time when the SCIM credential was created.
- Credential
Id string - The ID of the SCIM credential.
- Credential
Type string - (Available since v1.245.0) The type of the SCIM credential.
- Expire
Time string - (Available since v1.245.0) The time when the SCIM credential expires.
- Id string
- The provider-assigned unique ID for this managed resource.
- create
Time String - (Available since v1.245.0) The time when the SCIM credential was created.
- credential
Id String - The ID of the SCIM credential.
- credential
Type String - (Available since v1.245.0) The type of the SCIM credential.
- expire
Time String - (Available since v1.245.0) The time when the SCIM credential expires.
- id String
- The provider-assigned unique ID for this managed resource.
- create
Time string - (Available since v1.245.0) The time when the SCIM credential was created.
- credential
Id string - The ID of the SCIM credential.
- credential
Type string - (Available since v1.245.0) The type of the SCIM credential.
- expire
Time string - (Available since v1.245.0) The time when the SCIM credential expires.
- id string
- The provider-assigned unique ID for this managed resource.
- create_
time str - (Available since v1.245.0) The time when the SCIM credential was created.
- credential_
id str - The ID of the SCIM credential.
- credential_
type str - (Available since v1.245.0) The type of the SCIM credential.
- expire_
time str - (Available since v1.245.0) The time when the SCIM credential expires.
- id str
- The provider-assigned unique ID for this managed resource.
- create
Time String - (Available since v1.245.0) The time when the SCIM credential was created.
- credential
Id String - The ID of the SCIM credential.
- credential
Type String - (Available since v1.245.0) The type of the SCIM credential.
- expire
Time String - (Available since v1.245.0) The time when the SCIM credential expires.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing ScimServerCredential Resource
Get an existing ScimServerCredential 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?: ScimServerCredentialState, opts?: CustomResourceOptions): ScimServerCredential
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
create_time: Optional[str] = None,
credential_id: Optional[str] = None,
credential_secret_file: Optional[str] = None,
credential_type: Optional[str] = None,
directory_id: Optional[str] = None,
expire_time: Optional[str] = None,
status: Optional[str] = None) -> ScimServerCredential
func GetScimServerCredential(ctx *Context, name string, id IDInput, state *ScimServerCredentialState, opts ...ResourceOption) (*ScimServerCredential, error)
public static ScimServerCredential Get(string name, Input<string> id, ScimServerCredentialState? state, CustomResourceOptions? opts = null)
public static ScimServerCredential get(String name, Output<String> id, ScimServerCredentialState state, CustomResourceOptions options)
resources: _: type: alicloud:cloudsso:ScimServerCredential get: id: ${id}
- 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.
- Create
Time string - (Available since v1.245.0) The time when the SCIM credential was created.
- Credential
Id string - The ID of the SCIM credential.
- Credential
Secret stringFile - The name of file that can save Credential ID and Credential Secret. Strongly suggest you to specified it when you creating credential, otherwise, you wouldn't get its secret ever.
- Credential
Type string - (Available since v1.245.0) The type of the SCIM credential.
- Directory
Id string - The ID of the Directory.
- Expire
Time string - (Available since v1.245.0) The time when the SCIM credential expires.
- Status string
- The status of the SCIM Server Credential. Valid values:
Enabled
,Disabled
.
- Create
Time string - (Available since v1.245.0) The time when the SCIM credential was created.
- Credential
Id string - The ID of the SCIM credential.
- Credential
Secret stringFile - The name of file that can save Credential ID and Credential Secret. Strongly suggest you to specified it when you creating credential, otherwise, you wouldn't get its secret ever.
- Credential
Type string - (Available since v1.245.0) The type of the SCIM credential.
- Directory
Id string - The ID of the Directory.
- Expire
Time string - (Available since v1.245.0) The time when the SCIM credential expires.
- Status string
- The status of the SCIM Server Credential. Valid values:
Enabled
,Disabled
.
- create
Time String - (Available since v1.245.0) The time when the SCIM credential was created.
- credential
Id String - The ID of the SCIM credential.
- credential
Secret StringFile - The name of file that can save Credential ID and Credential Secret. Strongly suggest you to specified it when you creating credential, otherwise, you wouldn't get its secret ever.
- credential
Type String - (Available since v1.245.0) The type of the SCIM credential.
- directory
Id String - The ID of the Directory.
- expire
Time String - (Available since v1.245.0) The time when the SCIM credential expires.
- status String
- The status of the SCIM Server Credential. Valid values:
Enabled
,Disabled
.
- create
Time string - (Available since v1.245.0) The time when the SCIM credential was created.
- credential
Id string - The ID of the SCIM credential.
- credential
Secret stringFile - The name of file that can save Credential ID and Credential Secret. Strongly suggest you to specified it when you creating credential, otherwise, you wouldn't get its secret ever.
- credential
Type string - (Available since v1.245.0) The type of the SCIM credential.
- directory
Id string - The ID of the Directory.
- expire
Time string - (Available since v1.245.0) The time when the SCIM credential expires.
- status string
- The status of the SCIM Server Credential. Valid values:
Enabled
,Disabled
.
- create_
time str - (Available since v1.245.0) The time when the SCIM credential was created.
- credential_
id str - The ID of the SCIM credential.
- credential_
secret_ strfile - The name of file that can save Credential ID and Credential Secret. Strongly suggest you to specified it when you creating credential, otherwise, you wouldn't get its secret ever.
- credential_
type str - (Available since v1.245.0) The type of the SCIM credential.
- directory_
id str - The ID of the Directory.
- expire_
time str - (Available since v1.245.0) The time when the SCIM credential expires.
- status str
- The status of the SCIM Server Credential. Valid values:
Enabled
,Disabled
.
- create
Time String - (Available since v1.245.0) The time when the SCIM credential was created.
- credential
Id String - The ID of the SCIM credential.
- credential
Secret StringFile - The name of file that can save Credential ID and Credential Secret. Strongly suggest you to specified it when you creating credential, otherwise, you wouldn't get its secret ever.
- credential
Type String - (Available since v1.245.0) The type of the SCIM credential.
- directory
Id String - The ID of the Directory.
- expire
Time String - (Available since v1.245.0) The time when the SCIM credential expires.
- status String
- The status of the SCIM Server Credential. Valid values:
Enabled
,Disabled
.
Import
Cloud SSO SCIM Server Credential can be imported using the id, e.g.
$ pulumi import alicloud:cloudsso/scimServerCredential:ScimServerCredential example <directory_id>:<credential_id>
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloud
Terraform Provider.