Google Cloud Native is in preview. Google Cloud Classic is fully supported.
google-native.sourcerepo/v1.Repo
Explore with Pulumi AI
Google Cloud Native is in preview. Google Cloud Classic is fully supported.
Creates a repo in the given project with the given name. If the named repository already exists, CreateRepo
returns ALREADY_EXISTS
.
Create Repo Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Repo(name: string, args?: RepoArgs, opts?: CustomResourceOptions);
@overload
def Repo(resource_name: str,
args: Optional[RepoArgs] = None,
opts: Optional[ResourceOptions] = None)
@overload
def Repo(resource_name: str,
opts: Optional[ResourceOptions] = None,
mirror_config: Optional[MirrorConfigArgs] = None,
name: Optional[str] = None,
project: Optional[str] = None,
pubsub_configs: Optional[Mapping[str, str]] = None,
size: Optional[str] = None,
url: Optional[str] = None)
func NewRepo(ctx *Context, name string, args *RepoArgs, opts ...ResourceOption) (*Repo, error)
public Repo(string name, RepoArgs? args = null, CustomResourceOptions? opts = null)
type: google-native:sourcerepo/v1:Repo
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 RepoArgs
- 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 RepoArgs
- 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 RepoArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args RepoArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args RepoArgs
- 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 repoResource = new GoogleNative.SourceRepo.V1.Repo("repoResource", new()
{
MirrorConfig = new GoogleNative.SourceRepo.V1.Inputs.MirrorConfigArgs
{
DeployKeyId = "string",
Url = "string",
WebhookId = "string",
},
Name = "string",
Project = "string",
PubsubConfigs =
{
{ "string", "string" },
},
Size = "string",
Url = "string",
});
example, err := sourcerepo.NewRepo(ctx, "repoResource", &sourcerepo.RepoArgs{
MirrorConfig: &sourcerepo.MirrorConfigArgs{
DeployKeyId: pulumi.String("string"),
Url: pulumi.String("string"),
WebhookId: pulumi.String("string"),
},
Name: pulumi.String("string"),
Project: pulumi.String("string"),
PubsubConfigs: pulumi.StringMap{
"string": pulumi.String("string"),
},
Size: pulumi.String("string"),
Url: pulumi.String("string"),
})
var repoResource = new Repo("repoResource", RepoArgs.builder()
.mirrorConfig(MirrorConfigArgs.builder()
.deployKeyId("string")
.url("string")
.webhookId("string")
.build())
.name("string")
.project("string")
.pubsubConfigs(Map.of("string", "string"))
.size("string")
.url("string")
.build());
repo_resource = google_native.sourcerepo.v1.Repo("repoResource",
mirror_config={
"deploy_key_id": "string",
"url": "string",
"webhook_id": "string",
},
name="string",
project="string",
pubsub_configs={
"string": "string",
},
size="string",
url="string")
const repoResource = new google_native.sourcerepo.v1.Repo("repoResource", {
mirrorConfig: {
deployKeyId: "string",
url: "string",
webhookId: "string",
},
name: "string",
project: "string",
pubsubConfigs: {
string: "string",
},
size: "string",
url: "string",
});
type: google-native:sourcerepo/v1:Repo
properties:
mirrorConfig:
deployKeyId: string
url: string
webhookId: string
name: string
project: string
pubsubConfigs:
string: string
size: string
url: string
Repo 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 Repo resource accepts the following input properties:
- Mirror
Config Pulumi.Google Native. Source Repo. V1. Inputs. Mirror Config - How this repository mirrors a repository managed by another service. Read-only field.
- Name string
- Resource name of the repository, of the form
projects//repos/
. The repo name may contain slashes. eg,projects/myproject/repos/name/with/slash
- Project string
- Pubsub
Configs Dictionary<string, string> - How this repository publishes a change in the repository through Cloud Pub/Sub. Keyed by the topic names.
- Size string
- The disk usage of the repo, in bytes. Read-only field. Size is only returned by GetRepo.
- Url string
- URL to clone the repository from Google Cloud Source Repositories. Read-only field.
- Mirror
Config MirrorConfig Args - How this repository mirrors a repository managed by another service. Read-only field.
- Name string
- Resource name of the repository, of the form
projects//repos/
. The repo name may contain slashes. eg,projects/myproject/repos/name/with/slash
- Project string
- Pubsub
Configs map[string]string - How this repository publishes a change in the repository through Cloud Pub/Sub. Keyed by the topic names.
- Size string
- The disk usage of the repo, in bytes. Read-only field. Size is only returned by GetRepo.
- Url string
- URL to clone the repository from Google Cloud Source Repositories. Read-only field.
- mirror
Config MirrorConfig - How this repository mirrors a repository managed by another service. Read-only field.
- name String
- Resource name of the repository, of the form
projects//repos/
. The repo name may contain slashes. eg,projects/myproject/repos/name/with/slash
- project String
- pubsub
Configs Map<String,String> - How this repository publishes a change in the repository through Cloud Pub/Sub. Keyed by the topic names.
- size String
- The disk usage of the repo, in bytes. Read-only field. Size is only returned by GetRepo.
- url String
- URL to clone the repository from Google Cloud Source Repositories. Read-only field.
- mirror
Config MirrorConfig - How this repository mirrors a repository managed by another service. Read-only field.
- name string
- Resource name of the repository, of the form
projects//repos/
. The repo name may contain slashes. eg,projects/myproject/repos/name/with/slash
- project string
- pubsub
Configs {[key: string]: string} - How this repository publishes a change in the repository through Cloud Pub/Sub. Keyed by the topic names.
- size string
- The disk usage of the repo, in bytes. Read-only field. Size is only returned by GetRepo.
- url string
- URL to clone the repository from Google Cloud Source Repositories. Read-only field.
- mirror_
config MirrorConfig Args - How this repository mirrors a repository managed by another service. Read-only field.
- name str
- Resource name of the repository, of the form
projects//repos/
. The repo name may contain slashes. eg,projects/myproject/repos/name/with/slash
- project str
- pubsub_
configs Mapping[str, str] - How this repository publishes a change in the repository through Cloud Pub/Sub. Keyed by the topic names.
- size str
- The disk usage of the repo, in bytes. Read-only field. Size is only returned by GetRepo.
- url str
- URL to clone the repository from Google Cloud Source Repositories. Read-only field.
- mirror
Config Property Map - How this repository mirrors a repository managed by another service. Read-only field.
- name String
- Resource name of the repository, of the form
projects//repos/
. The repo name may contain slashes. eg,projects/myproject/repos/name/with/slash
- project String
- pubsub
Configs Map<String> - How this repository publishes a change in the repository through Cloud Pub/Sub. Keyed by the topic names.
- size String
- The disk usage of the repo, in bytes. Read-only field. Size is only returned by GetRepo.
- url String
- URL to clone the repository from Google Cloud Source Repositories. Read-only field.
Outputs
All input properties are implicitly available as output properties. Additionally, the Repo resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Supporting Types
MirrorConfig, MirrorConfigArgs
- Deploy
Key stringId - ID of the SSH deploy key at the other hosting service. Removing this key from the other service would deauthorize Google Cloud Source Repositories from mirroring.
- Url string
- URL of the main repository at the other hosting service.
- Webhook
Id string - ID of the webhook listening to updates to trigger mirroring. Removing this webhook from the other hosting service will stop Google Cloud Source Repositories from receiving notifications, and thereby disabling mirroring.
- Deploy
Key stringId - ID of the SSH deploy key at the other hosting service. Removing this key from the other service would deauthorize Google Cloud Source Repositories from mirroring.
- Url string
- URL of the main repository at the other hosting service.
- Webhook
Id string - ID of the webhook listening to updates to trigger mirroring. Removing this webhook from the other hosting service will stop Google Cloud Source Repositories from receiving notifications, and thereby disabling mirroring.
- deploy
Key StringId - ID of the SSH deploy key at the other hosting service. Removing this key from the other service would deauthorize Google Cloud Source Repositories from mirroring.
- url String
- URL of the main repository at the other hosting service.
- webhook
Id String - ID of the webhook listening to updates to trigger mirroring. Removing this webhook from the other hosting service will stop Google Cloud Source Repositories from receiving notifications, and thereby disabling mirroring.
- deploy
Key stringId - ID of the SSH deploy key at the other hosting service. Removing this key from the other service would deauthorize Google Cloud Source Repositories from mirroring.
- url string
- URL of the main repository at the other hosting service.
- webhook
Id string - ID of the webhook listening to updates to trigger mirroring. Removing this webhook from the other hosting service will stop Google Cloud Source Repositories from receiving notifications, and thereby disabling mirroring.
- deploy_
key_ strid - ID of the SSH deploy key at the other hosting service. Removing this key from the other service would deauthorize Google Cloud Source Repositories from mirroring.
- url str
- URL of the main repository at the other hosting service.
- webhook_
id str - ID of the webhook listening to updates to trigger mirroring. Removing this webhook from the other hosting service will stop Google Cloud Source Repositories from receiving notifications, and thereby disabling mirroring.
- deploy
Key StringId - ID of the SSH deploy key at the other hosting service. Removing this key from the other service would deauthorize Google Cloud Source Repositories from mirroring.
- url String
- URL of the main repository at the other hosting service.
- webhook
Id String - ID of the webhook listening to updates to trigger mirroring. Removing this webhook from the other hosting service will stop Google Cloud Source Repositories from receiving notifications, and thereby disabling mirroring.
MirrorConfigResponse, MirrorConfigResponseArgs
- Deploy
Key stringId - ID of the SSH deploy key at the other hosting service. Removing this key from the other service would deauthorize Google Cloud Source Repositories from mirroring.
- Url string
- URL of the main repository at the other hosting service.
- Webhook
Id string - ID of the webhook listening to updates to trigger mirroring. Removing this webhook from the other hosting service will stop Google Cloud Source Repositories from receiving notifications, and thereby disabling mirroring.
- Deploy
Key stringId - ID of the SSH deploy key at the other hosting service. Removing this key from the other service would deauthorize Google Cloud Source Repositories from mirroring.
- Url string
- URL of the main repository at the other hosting service.
- Webhook
Id string - ID of the webhook listening to updates to trigger mirroring. Removing this webhook from the other hosting service will stop Google Cloud Source Repositories from receiving notifications, and thereby disabling mirroring.
- deploy
Key StringId - ID of the SSH deploy key at the other hosting service. Removing this key from the other service would deauthorize Google Cloud Source Repositories from mirroring.
- url String
- URL of the main repository at the other hosting service.
- webhook
Id String - ID of the webhook listening to updates to trigger mirroring. Removing this webhook from the other hosting service will stop Google Cloud Source Repositories from receiving notifications, and thereby disabling mirroring.
- deploy
Key stringId - ID of the SSH deploy key at the other hosting service. Removing this key from the other service would deauthorize Google Cloud Source Repositories from mirroring.
- url string
- URL of the main repository at the other hosting service.
- webhook
Id string - ID of the webhook listening to updates to trigger mirroring. Removing this webhook from the other hosting service will stop Google Cloud Source Repositories from receiving notifications, and thereby disabling mirroring.
- deploy_
key_ strid - ID of the SSH deploy key at the other hosting service. Removing this key from the other service would deauthorize Google Cloud Source Repositories from mirroring.
- url str
- URL of the main repository at the other hosting service.
- webhook_
id str - ID of the webhook listening to updates to trigger mirroring. Removing this webhook from the other hosting service will stop Google Cloud Source Repositories from receiving notifications, and thereby disabling mirroring.
- deploy
Key StringId - ID of the SSH deploy key at the other hosting service. Removing this key from the other service would deauthorize Google Cloud Source Repositories from mirroring.
- url String
- URL of the main repository at the other hosting service.
- webhook
Id String - ID of the webhook listening to updates to trigger mirroring. Removing this webhook from the other hosting service will stop Google Cloud Source Repositories from receiving notifications, and thereby disabling mirroring.
Package Details
- Repository
- Google Cloud Native pulumi/pulumi-google-native
- License
- Apache-2.0
Google Cloud Native is in preview. Google Cloud Classic is fully supported.