Class RepositoryDeployKey
Provides a GitHub repository deploy key resource.
A deploy key is an SSH key that is stored on your server and grants access to a single GitHub repository. This key is attached directly to the repository instead of to a personal user account.
This resource allows you to add/remove repository deploy keys.
Further documentation on GitHub repository deploy keys:
Example Usage
using Pulumi;
using Github = Pulumi.Github;
class MyStack : Stack
{
public MyStack()
{
// Add a deploy key
var exampleRepositoryDeployKey = new Github.RepositoryDeployKey("exampleRepositoryDeployKey", new Github.RepositoryDeployKeyArgs
{
Key = "ssh-rsa AAA...",
ReadOnly = "false",
Repository = "test-repo",
Title = "Repository test key",
});
}
}
Inherited Members
Namespace: Pulumi.Github
Assembly: Pulumi.Github.dll
Syntax
public class RepositoryDeployKey : CustomResource
Constructors
View SourceRepositoryDeployKey(String, RepositoryDeployKeyArgs, CustomResourceOptions)
Create a RepositoryDeployKey resource with the given unique name, arguments, and options.
Declaration
public RepositoryDeployKey(string name, RepositoryDeployKeyArgs args, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resource |
| RepositoryDeployKeyArgs | args | The arguments used to populate this resource's properties |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Properties
View SourceEtag
Declaration
public Output<string> Etag { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Key
A SSH key.
Declaration
public Output<string> Key { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
ReadOnly
A boolean qualifying the key to be either read only or read/write.
Declaration
public Output<bool?> ReadOnly { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Nullable<System.Boolean>> |
Repository
Name of the GitHub repository.
Declaration
public Output<string> Repository { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Title
A title.
Declaration
public Output<string> Title { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Methods
View SourceGet(String, Input<String>, RepositoryDeployKeyState, CustomResourceOptions)
Get an existing RepositoryDeployKey resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
Declaration
public static RepositoryDeployKey Get(string name, Input<string> id, RepositoryDeployKeyState state = null, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resulting resource. |
| Input<System.String> | id | The unique provider ID of the resource to lookup. |
| RepositoryDeployKeyState | state | Any extra arguments used during the lookup. |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Returns
| Type | Description |
|---|---|
| RepositoryDeployKey |