octopusdeploy.User
Explore with Pulumi AI
This resource manages users in Octopus Deploy.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as octopusdeploy from "@pulumi/octopusdeploy";
const example = new octopusdeploy.User("example", {
displayName: "Bob Smith",
emailAddress: "bob.smith@example.com",
identities: [{
claims: [
{
isIdentifyingClaim: true,
name: "email",
value: "bob.smith@example.com",
},
{
isIdentifyingClaim: false,
name: "dn",
value: "Bob Smith",
},
],
provider: "Octopus ID",
}],
isActive: true,
isService: false,
password: "###########",
username: "[username]",
});
import pulumi
import pulumi_octopusdeploy as octopusdeploy
example = octopusdeploy.User("example",
display_name="Bob Smith",
email_address="bob.smith@example.com",
identities=[{
"claims": [
{
"is_identifying_claim": True,
"name": "email",
"value": "bob.smith@example.com",
},
{
"is_identifying_claim": False,
"name": "dn",
"value": "Bob Smith",
},
],
"provider": "Octopus ID",
}],
is_active=True,
is_service=False,
password="###########",
username="[username]")
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/octopusdeploy/octopusdeploy"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := octopusdeploy.NewUser(ctx, "example", &octopusdeploy.UserArgs{
DisplayName: pulumi.String("Bob Smith"),
EmailAddress: pulumi.String("bob.smith@example.com"),
Identities: octopusdeploy.UserIdentityArray{
&octopusdeploy.UserIdentityArgs{
Claims: octopusdeploy.UserIdentityClaimArray{
&octopusdeploy.UserIdentityClaimArgs{
IsIdentifyingClaim: pulumi.Bool(true),
Name: pulumi.String("email"),
Value: pulumi.String("bob.smith@example.com"),
},
&octopusdeploy.UserIdentityClaimArgs{
IsIdentifyingClaim: pulumi.Bool(false),
Name: pulumi.String("dn"),
Value: pulumi.String("Bob Smith"),
},
},
Provider: pulumi.String("Octopus ID"),
},
},
IsActive: pulumi.Bool(true),
IsService: pulumi.Bool(false),
Password: pulumi.String("###########"),
Username: pulumi.String("[username]"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Octopusdeploy = Pulumi.Octopusdeploy;
return await Deployment.RunAsync(() =>
{
var example = new Octopusdeploy.User("example", new()
{
DisplayName = "Bob Smith",
EmailAddress = "bob.smith@example.com",
Identities = new[]
{
new Octopusdeploy.Inputs.UserIdentityArgs
{
Claims = new[]
{
new Octopusdeploy.Inputs.UserIdentityClaimArgs
{
IsIdentifyingClaim = true,
Name = "email",
Value = "bob.smith@example.com",
},
new Octopusdeploy.Inputs.UserIdentityClaimArgs
{
IsIdentifyingClaim = false,
Name = "dn",
Value = "Bob Smith",
},
},
Provider = "Octopus ID",
},
},
IsActive = true,
IsService = false,
Password = "###########",
Username = "[username]",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.octopusdeploy.User;
import com.pulumi.octopusdeploy.UserArgs;
import com.pulumi.octopusdeploy.inputs.UserIdentityArgs;
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 example = new User("example", UserArgs.builder()
.displayName("Bob Smith")
.emailAddress("bob.smith@example.com")
.identities(UserIdentityArgs.builder()
.claims(
UserIdentityClaimArgs.builder()
.isIdentifyingClaim(true)
.name("email")
.value("bob.smith@example.com")
.build(),
UserIdentityClaimArgs.builder()
.isIdentifyingClaim(false)
.name("dn")
.value("Bob Smith")
.build())
.provider("Octopus ID")
.build())
.isActive(true)
.isService(false)
.password("###########")
.username("[username]")
.build());
}
}
resources:
example:
type: octopusdeploy:User
properties:
displayName: Bob Smith
emailAddress: bob.smith@example.com
identities:
- claims:
- isIdentifyingClaim: true
name: email
value: bob.smith@example.com
- isIdentifyingClaim: false
name: dn
value: Bob Smith
provider: Octopus ID
isActive: true
isService: false
password: '###########'
# get from secure environment/store
username: '[username]'
Create User Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new User(name: string, args: UserArgs, opts?: CustomResourceOptions);
@overload
def User(resource_name: str,
args: UserArgs,
opts: Optional[ResourceOptions] = None)
@overload
def User(resource_name: str,
opts: Optional[ResourceOptions] = None,
display_name: Optional[str] = None,
username: Optional[str] = None,
email_address: Optional[str] = None,
identities: Optional[Sequence[UserIdentityArgs]] = None,
is_active: Optional[bool] = None,
is_service: Optional[bool] = None,
password: Optional[str] = None)
func NewUser(ctx *Context, name string, args UserArgs, opts ...ResourceOption) (*User, error)
public User(string name, UserArgs args, CustomResourceOptions? opts = null)
type: octopusdeploy:User
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 UserArgs
- 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 UserArgs
- 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 UserArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args UserArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args UserArgs
- 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 userResource = new Octopusdeploy.User("userResource", new()
{
DisplayName = "string",
Username = "string",
EmailAddress = "string",
Identities = new[]
{
new Octopusdeploy.Inputs.UserIdentityArgs
{
Claims = new[]
{
new Octopusdeploy.Inputs.UserIdentityClaimArgs
{
IsIdentifyingClaim = false,
Name = "string",
Value = "string",
},
},
Provider = "string",
},
},
IsActive = false,
IsService = false,
Password = "string",
});
example, err := octopusdeploy.NewUser(ctx, "userResource", &octopusdeploy.UserArgs{
DisplayName: pulumi.String("string"),
Username: pulumi.String("string"),
EmailAddress: pulumi.String("string"),
Identities: octopusdeploy.UserIdentityArray{
&octopusdeploy.UserIdentityArgs{
Claims: octopusdeploy.UserIdentityClaimArray{
&octopusdeploy.UserIdentityClaimArgs{
IsIdentifyingClaim: pulumi.Bool(false),
Name: pulumi.String("string"),
Value: pulumi.String("string"),
},
},
Provider: pulumi.String("string"),
},
},
IsActive: pulumi.Bool(false),
IsService: pulumi.Bool(false),
Password: pulumi.String("string"),
})
var userResource = new User("userResource", UserArgs.builder()
.displayName("string")
.username("string")
.emailAddress("string")
.identities(UserIdentityArgs.builder()
.claims(UserIdentityClaimArgs.builder()
.isIdentifyingClaim(false)
.name("string")
.value("string")
.build())
.provider("string")
.build())
.isActive(false)
.isService(false)
.password("string")
.build());
user_resource = octopusdeploy.User("userResource",
display_name="string",
username="string",
email_address="string",
identities=[{
"claims": [{
"is_identifying_claim": False,
"name": "string",
"value": "string",
}],
"provider": "string",
}],
is_active=False,
is_service=False,
password="string")
const userResource = new octopusdeploy.User("userResource", {
displayName: "string",
username: "string",
emailAddress: "string",
identities: [{
claims: [{
isIdentifyingClaim: false,
name: "string",
value: "string",
}],
provider: "string",
}],
isActive: false,
isService: false,
password: "string",
});
type: octopusdeploy:User
properties:
displayName: string
emailAddress: string
identities:
- claims:
- isIdentifyingClaim: false
name: string
value: string
provider: string
isActive: false
isService: false
password: string
username: string
User 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 User resource accepts the following input properties:
- Display
Name string - The display name of this resource.
- Username string
- The username associated with this resource.
- Email
Address string - The email address of this resource.
- Identities
List<User
Identity> - The identities associated with the user.
- Is
Active bool - Specifies whether or not the user is active.
- Is
Service bool - Specifies whether or not the user is a service account.
- Password string
- The password associated with this resource.
- Display
Name string - The display name of this resource.
- Username string
- The username associated with this resource.
- Email
Address string - The email address of this resource.
- Identities
[]User
Identity Args - The identities associated with the user.
- Is
Active bool - Specifies whether or not the user is active.
- Is
Service bool - Specifies whether or not the user is a service account.
- Password string
- The password associated with this resource.
- display
Name String - The display name of this resource.
- username String
- The username associated with this resource.
- email
Address String - The email address of this resource.
- identities
List<User
Identity> - The identities associated with the user.
- is
Active Boolean - Specifies whether or not the user is active.
- is
Service Boolean - Specifies whether or not the user is a service account.
- password String
- The password associated with this resource.
- display
Name string - The display name of this resource.
- username string
- The username associated with this resource.
- email
Address string - The email address of this resource.
- identities
User
Identity[] - The identities associated with the user.
- is
Active boolean - Specifies whether or not the user is active.
- is
Service boolean - Specifies whether or not the user is a service account.
- password string
- The password associated with this resource.
- display_
name str - The display name of this resource.
- username str
- The username associated with this resource.
- email_
address str - The email address of this resource.
- identities
Sequence[User
Identity Args] - The identities associated with the user.
- is_
active bool - Specifies whether or not the user is active.
- is_
service bool - Specifies whether or not the user is a service account.
- password str
- The password associated with this resource.
- display
Name String - The display name of this resource.
- username String
- The username associated with this resource.
- email
Address String - The email address of this resource.
- identities List<Property Map>
- The identities associated with the user.
- is
Active Boolean - Specifies whether or not the user is active.
- is
Service Boolean - Specifies whether or not the user is a service account.
- password String
- The password associated with this resource.
Outputs
All input properties are implicitly available as output properties. Additionally, the User resource produces the following output properties:
- Can
Password boolBe Edited - Specifies whether or not the password can be edited.
- Id string
- The provider-assigned unique ID for this managed resource.
- Is
Requestor bool - Specifies whether or not the user is the requestor.
- Can
Password boolBe Edited - Specifies whether or not the password can be edited.
- Id string
- The provider-assigned unique ID for this managed resource.
- Is
Requestor bool - Specifies whether or not the user is the requestor.
- can
Password BooleanBe Edited - Specifies whether or not the password can be edited.
- id String
- The provider-assigned unique ID for this managed resource.
- is
Requestor Boolean - Specifies whether or not the user is the requestor.
- can
Password booleanBe Edited - Specifies whether or not the password can be edited.
- id string
- The provider-assigned unique ID for this managed resource.
- is
Requestor boolean - Specifies whether or not the user is the requestor.
- can_
password_ boolbe_ edited - Specifies whether or not the password can be edited.
- id str
- The provider-assigned unique ID for this managed resource.
- is_
requestor bool - Specifies whether or not the user is the requestor.
- can
Password BooleanBe Edited - Specifies whether or not the password can be edited.
- id String
- The provider-assigned unique ID for this managed resource.
- is
Requestor Boolean - Specifies whether or not the user is the requestor.
Look up Existing User Resource
Get an existing User 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?: UserState, opts?: CustomResourceOptions): User
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
can_password_be_edited: Optional[bool] = None,
display_name: Optional[str] = None,
email_address: Optional[str] = None,
identities: Optional[Sequence[UserIdentityArgs]] = None,
is_active: Optional[bool] = None,
is_requestor: Optional[bool] = None,
is_service: Optional[bool] = None,
password: Optional[str] = None,
username: Optional[str] = None) -> User
func GetUser(ctx *Context, name string, id IDInput, state *UserState, opts ...ResourceOption) (*User, error)
public static User Get(string name, Input<string> id, UserState? state, CustomResourceOptions? opts = null)
public static User get(String name, Output<String> id, UserState state, CustomResourceOptions options)
resources: _: type: octopusdeploy:User 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.
- Can
Password boolBe Edited - Specifies whether or not the password can be edited.
- Display
Name string - The display name of this resource.
- Email
Address string - The email address of this resource.
- Identities
List<User
Identity> - The identities associated with the user.
- Is
Active bool - Specifies whether or not the user is active.
- Is
Requestor bool - Specifies whether or not the user is the requestor.
- Is
Service bool - Specifies whether or not the user is a service account.
- Password string
- The password associated with this resource.
- Username string
- The username associated with this resource.
- Can
Password boolBe Edited - Specifies whether or not the password can be edited.
- Display
Name string - The display name of this resource.
- Email
Address string - The email address of this resource.
- Identities
[]User
Identity Args - The identities associated with the user.
- Is
Active bool - Specifies whether or not the user is active.
- Is
Requestor bool - Specifies whether or not the user is the requestor.
- Is
Service bool - Specifies whether or not the user is a service account.
- Password string
- The password associated with this resource.
- Username string
- The username associated with this resource.
- can
Password BooleanBe Edited - Specifies whether or not the password can be edited.
- display
Name String - The display name of this resource.
- email
Address String - The email address of this resource.
- identities
List<User
Identity> - The identities associated with the user.
- is
Active Boolean - Specifies whether or not the user is active.
- is
Requestor Boolean - Specifies whether or not the user is the requestor.
- is
Service Boolean - Specifies whether or not the user is a service account.
- password String
- The password associated with this resource.
- username String
- The username associated with this resource.
- can
Password booleanBe Edited - Specifies whether or not the password can be edited.
- display
Name string - The display name of this resource.
- email
Address string - The email address of this resource.
- identities
User
Identity[] - The identities associated with the user.
- is
Active boolean - Specifies whether or not the user is active.
- is
Requestor boolean - Specifies whether or not the user is the requestor.
- is
Service boolean - Specifies whether or not the user is a service account.
- password string
- The password associated with this resource.
- username string
- The username associated with this resource.
- can_
password_ boolbe_ edited - Specifies whether or not the password can be edited.
- display_
name str - The display name of this resource.
- email_
address str - The email address of this resource.
- identities
Sequence[User
Identity Args] - The identities associated with the user.
- is_
active bool - Specifies whether or not the user is active.
- is_
requestor bool - Specifies whether or not the user is the requestor.
- is_
service bool - Specifies whether or not the user is a service account.
- password str
- The password associated with this resource.
- username str
- The username associated with this resource.
- can
Password BooleanBe Edited - Specifies whether or not the password can be edited.
- display
Name String - The display name of this resource.
- email
Address String - The email address of this resource.
- identities List<Property Map>
- The identities associated with the user.
- is
Active Boolean - Specifies whether or not the user is active.
- is
Requestor Boolean - Specifies whether or not the user is the requestor.
- is
Service Boolean - Specifies whether or not the user is a service account.
- password String
- The password associated with this resource.
- username String
- The username associated with this resource.
Supporting Types
UserIdentity, UserIdentityArgs
- Claims
List<User
Identity Claim> - The claim associated with the identity.
- Provider string
- The identity provider.
- Claims
[]User
Identity Claim - The claim associated with the identity.
- Provider string
- The identity provider.
- claims
List<User
Identity Claim> - The claim associated with the identity.
- provider String
- The identity provider.
- claims
User
Identity Claim[] - The claim associated with the identity.
- provider string
- The identity provider.
- claims
Sequence[User
Identity Claim] - The claim associated with the identity.
- provider str
- The identity provider.
- claims List<Property Map>
- The claim associated with the identity.
- provider String
- The identity provider.
UserIdentityClaim, UserIdentityClaimArgs
- Is
Identifying boolClaim - Specifies whether or not the claim is an identifying claim.
- Name string
- The name of this resource.
- Value string
- The value of this resource.
- Is
Identifying boolClaim - Specifies whether or not the claim is an identifying claim.
- Name string
- The name of this resource.
- Value string
- The value of this resource.
- is
Identifying BooleanClaim - Specifies whether or not the claim is an identifying claim.
- name String
- The name of this resource.
- value String
- The value of this resource.
- is
Identifying booleanClaim - Specifies whether or not the claim is an identifying claim.
- name string
- The name of this resource.
- value string
- The value of this resource.
- is_
identifying_ boolclaim - Specifies whether or not the claim is an identifying claim.
- name str
- The name of this resource.
- value str
- The value of this resource.
- is
Identifying BooleanClaim - Specifies whether or not the claim is an identifying claim.
- name String
- The name of this resource.
- value String
- The value of this resource.
Import
$ pulumi import octopusdeploy:index/user:User [options] octopusdeploy_user.<name> <user-id>
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- octopusdeploy octopusdeploylabs/terraform-provider-octopusdeploy
- License
- Notes
- This Pulumi package is based on the
octopusdeploy
Terraform Provider.