gcp.artifactregistry.Repository
A repository for storing artifacts
To get more information about Repository, see:
- API documentation
- How-to Guides
Example Usage
Artifact Registry Repository Basic
using System.Collections.Generic;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var my_repo = new Gcp.ArtifactRegistry.Repository("my-repo", new()
{
Description = "example docker repository",
Format = "DOCKER",
Location = "us-central1",
RepositoryId = "my-repository",
});
});
package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v6/go/gcp/artifactregistry"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := artifactregistry.NewRepository(ctx, "my-repo", &artifactregistry.RepositoryArgs{
Description: pulumi.String("example docker repository"),
Format: pulumi.String("DOCKER"),
Location: pulumi.String("us-central1"),
RepositoryId: pulumi.String("my-repository"),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.artifactregistry.Repository;
import com.pulumi.gcp.artifactregistry.RepositoryArgs;
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 my_repo = new Repository("my-repo", RepositoryArgs.builder()
.description("example docker repository")
.format("DOCKER")
.location("us-central1")
.repositoryId("my-repository")
.build());
}
}
import pulumi
import pulumi_gcp as gcp
my_repo = gcp.artifactregistry.Repository("my-repo",
description="example docker repository",
format="DOCKER",
location="us-central1",
repository_id="my-repository")
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const my_repo = new gcp.artifactregistry.Repository("my-repo", {
description: "example docker repository",
format: "DOCKER",
location: "us-central1",
repositoryId: "my-repository",
});
resources:
my-repo:
type: gcp:artifactregistry:Repository
properties:
description: example docker repository
format: DOCKER
location: us-central1
repositoryId: my-repository
Artifact Registry Repository Cmek
using System.Collections.Generic;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var project = Gcp.Organizations.GetProject.Invoke();
var cryptoKey = new Gcp.Kms.CryptoKeyIAMMember("cryptoKey", new()
{
CryptoKeyId = "kms-key",
Role = "roles/cloudkms.cryptoKeyEncrypterDecrypter",
Member = $"serviceAccount:service-{project.Apply(getProjectResult => getProjectResult.Number)}@gcp-sa-artifactregistry.iam.gserviceaccount.com",
});
var my_repo = new Gcp.ArtifactRegistry.Repository("my-repo", new()
{
Location = "us-central1",
RepositoryId = "my-repository",
Description = "example docker repository with cmek",
Format = "DOCKER",
KmsKeyName = "kms-key",
}, new CustomResourceOptions
{
DependsOn = new[]
{
cryptoKey,
},
});
});
package main
import (
"fmt"
"github.com/pulumi/pulumi-gcp/sdk/v6/go/gcp/artifactregistry"
"github.com/pulumi/pulumi-gcp/sdk/v6/go/gcp/kms"
"github.com/pulumi/pulumi-gcp/sdk/v6/go/gcp/organizations"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
project, err := organizations.LookupProject(ctx, nil, nil)
if err != nil {
return err
}
cryptoKey, err := kms.NewCryptoKeyIAMMember(ctx, "cryptoKey", &kms.CryptoKeyIAMMemberArgs{
CryptoKeyId: pulumi.String("kms-key"),
Role: pulumi.String("roles/cloudkms.cryptoKeyEncrypterDecrypter"),
Member: pulumi.String(fmt.Sprintf("serviceAccount:service-%v@gcp-sa-artifactregistry.iam.gserviceaccount.com", project.Number)),
})
if err != nil {
return err
}
_, err = artifactregistry.NewRepository(ctx, "my-repo", &artifactregistry.RepositoryArgs{
Location: pulumi.String("us-central1"),
RepositoryId: pulumi.String("my-repository"),
Description: pulumi.String("example docker repository with cmek"),
Format: pulumi.String("DOCKER"),
KmsKeyName: pulumi.String("kms-key"),
}, pulumi.DependsOn([]pulumi.Resource{
cryptoKey,
}))
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.organizations.OrganizationsFunctions;
import com.pulumi.gcp.organizations.inputs.GetProjectArgs;
import com.pulumi.gcp.kms.CryptoKeyIAMMember;
import com.pulumi.gcp.kms.CryptoKeyIAMMemberArgs;
import com.pulumi.gcp.artifactregistry.Repository;
import com.pulumi.gcp.artifactregistry.RepositoryArgs;
import com.pulumi.resources.CustomResourceOptions;
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 project = OrganizationsFunctions.getProject();
var cryptoKey = new CryptoKeyIAMMember("cryptoKey", CryptoKeyIAMMemberArgs.builder()
.cryptoKeyId("kms-key")
.role("roles/cloudkms.cryptoKeyEncrypterDecrypter")
.member(String.format("serviceAccount:service-%s@gcp-sa-artifactregistry.iam.gserviceaccount.com", project.applyValue(getProjectResult -> getProjectResult.number())))
.build());
var my_repo = new Repository("my-repo", RepositoryArgs.builder()
.location("us-central1")
.repositoryId("my-repository")
.description("example docker repository with cmek")
.format("DOCKER")
.kmsKeyName("kms-key")
.build(), CustomResourceOptions.builder()
.dependsOn(cryptoKey)
.build());
}
}
import pulumi
import pulumi_gcp as gcp
project = gcp.organizations.get_project()
crypto_key = gcp.kms.CryptoKeyIAMMember("cryptoKey",
crypto_key_id="kms-key",
role="roles/cloudkms.cryptoKeyEncrypterDecrypter",
member=f"serviceAccount:service-{project.number}@gcp-sa-artifactregistry.iam.gserviceaccount.com")
my_repo = gcp.artifactregistry.Repository("my-repo",
location="us-central1",
repository_id="my-repository",
description="example docker repository with cmek",
format="DOCKER",
kms_key_name="kms-key",
opts=pulumi.ResourceOptions(depends_on=[crypto_key]))
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const project = gcp.organizations.getProject({});
const cryptoKey = new gcp.kms.CryptoKeyIAMMember("cryptoKey", {
cryptoKeyId: "kms-key",
role: "roles/cloudkms.cryptoKeyEncrypterDecrypter",
member: project.then(project => `serviceAccount:service-${project.number}@gcp-sa-artifactregistry.iam.gserviceaccount.com`),
});
const my_repo = new gcp.artifactregistry.Repository("my-repo", {
location: "us-central1",
repositoryId: "my-repository",
description: "example docker repository with cmek",
format: "DOCKER",
kmsKeyName: "kms-key",
}, {
dependsOn: [cryptoKey],
});
resources:
my-repo:
type: gcp:artifactregistry:Repository
properties:
location: us-central1
repositoryId: my-repository
description: example docker repository with cmek
format: DOCKER
kmsKeyName: kms-key
options:
dependson:
- ${cryptoKey}
cryptoKey:
type: gcp:kms:CryptoKeyIAMMember
properties:
cryptoKeyId: kms-key
role: roles/cloudkms.cryptoKeyEncrypterDecrypter
member: serviceAccount:service-${project.number}@gcp-sa-artifactregistry.iam.gserviceaccount.com
variables:
project:
fn::invoke:
Function: gcp:organizations:getProject
Arguments: {}
Create Repository Resource
new Repository(name: string, args: RepositoryArgs, opts?: CustomResourceOptions);
@overload
def Repository(resource_name: str,
opts: Optional[ResourceOptions] = None,
description: Optional[str] = None,
format: Optional[str] = None,
kms_key_name: Optional[str] = None,
labels: Optional[Mapping[str, str]] = None,
location: Optional[str] = None,
maven_config: Optional[RepositoryMavenConfigArgs] = None,
project: Optional[str] = None,
repository_id: Optional[str] = None)
@overload
def Repository(resource_name: str,
args: RepositoryArgs,
opts: Optional[ResourceOptions] = None)
func NewRepository(ctx *Context, name string, args RepositoryArgs, opts ...ResourceOption) (*Repository, error)
public Repository(string name, RepositoryArgs args, CustomResourceOptions? opts = null)
public Repository(String name, RepositoryArgs args)
public Repository(String name, RepositoryArgs args, CustomResourceOptions options)
type: gcp:artifactregistry:Repository
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args RepositoryArgs
- 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 RepositoryArgs
- 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 RepositoryArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args RepositoryArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args RepositoryArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Repository 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 Repository resource accepts the following input properties:
- Format string
The format of packages that are stored in the repository. Supported formats can be found here. You can only create alpha formats if you are a member of the alpha user group.
- Repository
Id string The last part of the repository name, for example: "repo1"
- Description string
The user-provided description of the repository.
- Kms
Key stringName The Cloud KMS resource name of the customer managed encryption key that’s used to encrypt the contents of the Repository. Has the form:
projects/my-project/locations/my-region/keyRings/my-kr/cryptoKeys/my-key
. This value may not be changed after the Repository has been created.- Labels Dictionary<string, string>
Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.
- Location string
The name of the location this repository is located in.
- Maven
Config RepositoryMaven Config Args MavenRepositoryConfig is maven related repository details. Provides additional configuration details for repositories of the maven format type. Structure is documented below.
- Project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- Format string
The format of packages that are stored in the repository. Supported formats can be found here. You can only create alpha formats if you are a member of the alpha user group.
- Repository
Id string The last part of the repository name, for example: "repo1"
- Description string
The user-provided description of the repository.
- Kms
Key stringName The Cloud KMS resource name of the customer managed encryption key that’s used to encrypt the contents of the Repository. Has the form:
projects/my-project/locations/my-region/keyRings/my-kr/cryptoKeys/my-key
. This value may not be changed after the Repository has been created.- Labels map[string]string
Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.
- Location string
The name of the location this repository is located in.
- Maven
Config RepositoryMaven Config Args MavenRepositoryConfig is maven related repository details. Provides additional configuration details for repositories of the maven format type. Structure is documented below.
- Project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- format String
The format of packages that are stored in the repository. Supported formats can be found here. You can only create alpha formats if you are a member of the alpha user group.
- repository
Id String The last part of the repository name, for example: "repo1"
- description String
The user-provided description of the repository.
- kms
Key StringName The Cloud KMS resource name of the customer managed encryption key that’s used to encrypt the contents of the Repository. Has the form:
projects/my-project/locations/my-region/keyRings/my-kr/cryptoKeys/my-key
. This value may not be changed after the Repository has been created.- labels Map<String,String>
Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.
- location String
The name of the location this repository is located in.
- maven
Config RepositoryMaven Config Args MavenRepositoryConfig is maven related repository details. Provides additional configuration details for repositories of the maven format type. Structure is documented below.
- project String
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- format string
The format of packages that are stored in the repository. Supported formats can be found here. You can only create alpha formats if you are a member of the alpha user group.
- repository
Id string The last part of the repository name, for example: "repo1"
- description string
The user-provided description of the repository.
- kms
Key stringName The Cloud KMS resource name of the customer managed encryption key that’s used to encrypt the contents of the Repository. Has the form:
projects/my-project/locations/my-region/keyRings/my-kr/cryptoKeys/my-key
. This value may not be changed after the Repository has been created.- labels {[key: string]: string}
Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.
- location string
The name of the location this repository is located in.
- maven
Config RepositoryMaven Config Args MavenRepositoryConfig is maven related repository details. Provides additional configuration details for repositories of the maven format type. Structure is documented below.
- project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- format str
The format of packages that are stored in the repository. Supported formats can be found here. You can only create alpha formats if you are a member of the alpha user group.
- repository_
id str The last part of the repository name, for example: "repo1"
- description str
The user-provided description of the repository.
- kms_
key_ strname The Cloud KMS resource name of the customer managed encryption key that’s used to encrypt the contents of the Repository. Has the form:
projects/my-project/locations/my-region/keyRings/my-kr/cryptoKeys/my-key
. This value may not be changed after the Repository has been created.- labels Mapping[str, str]
Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.
- location str
The name of the location this repository is located in.
- maven_
config RepositoryMaven Config Args MavenRepositoryConfig is maven related repository details. Provides additional configuration details for repositories of the maven format type. Structure is documented below.
- project str
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- format String
The format of packages that are stored in the repository. Supported formats can be found here. You can only create alpha formats if you are a member of the alpha user group.
- repository
Id String The last part of the repository name, for example: "repo1"
- description String
The user-provided description of the repository.
- kms
Key StringName The Cloud KMS resource name of the customer managed encryption key that’s used to encrypt the contents of the Repository. Has the form:
projects/my-project/locations/my-region/keyRings/my-kr/cryptoKeys/my-key
. This value may not be changed after the Repository has been created.- labels Map<String>
Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.
- location String
The name of the location this repository is located in.
- maven
Config Property Map MavenRepositoryConfig is maven related repository details. Provides additional configuration details for repositories of the maven format type. Structure is documented below.
- project String
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
Outputs
All input properties are implicitly available as output properties. Additionally, the Repository resource produces the following output properties:
- Create
Time string The time when the repository was created.
- Id string
The provider-assigned unique ID for this managed resource.
- Name string
The name of the repository, for example: "projects/p1/locations/us-central1/repositories/repo1"
- Update
Time string The time when the repository was last updated.
- Create
Time string The time when the repository was created.
- Id string
The provider-assigned unique ID for this managed resource.
- Name string
The name of the repository, for example: "projects/p1/locations/us-central1/repositories/repo1"
- Update
Time string The time when the repository was last updated.
- create
Time String The time when the repository was created.
- id String
The provider-assigned unique ID for this managed resource.
- name String
The name of the repository, for example: "projects/p1/locations/us-central1/repositories/repo1"
- update
Time String The time when the repository was last updated.
- create
Time string The time when the repository was created.
- id string
The provider-assigned unique ID for this managed resource.
- name string
The name of the repository, for example: "projects/p1/locations/us-central1/repositories/repo1"
- update
Time string The time when the repository was last updated.
- create_
time str The time when the repository was created.
- id str
The provider-assigned unique ID for this managed resource.
- name str
The name of the repository, for example: "projects/p1/locations/us-central1/repositories/repo1"
- update_
time str The time when the repository was last updated.
- create
Time String The time when the repository was created.
- id String
The provider-assigned unique ID for this managed resource.
- name String
The name of the repository, for example: "projects/p1/locations/us-central1/repositories/repo1"
- update
Time String The time when the repository was last updated.
Look up Existing Repository Resource
Get an existing Repository 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?: RepositoryState, opts?: CustomResourceOptions): Repository
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
create_time: Optional[str] = None,
description: Optional[str] = None,
format: Optional[str] = None,
kms_key_name: Optional[str] = None,
labels: Optional[Mapping[str, str]] = None,
location: Optional[str] = None,
maven_config: Optional[RepositoryMavenConfigArgs] = None,
name: Optional[str] = None,
project: Optional[str] = None,
repository_id: Optional[str] = None,
update_time: Optional[str] = None) -> Repository
func GetRepository(ctx *Context, name string, id IDInput, state *RepositoryState, opts ...ResourceOption) (*Repository, error)
public static Repository Get(string name, Input<string> id, RepositoryState? state, CustomResourceOptions? opts = null)
public static Repository get(String name, Output<String> id, RepositoryState 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.
- Create
Time string The time when the repository was created.
- Description string
The user-provided description of the repository.
- Format string
The format of packages that are stored in the repository. Supported formats can be found here. You can only create alpha formats if you are a member of the alpha user group.
- Kms
Key stringName The Cloud KMS resource name of the customer managed encryption key that’s used to encrypt the contents of the Repository. Has the form:
projects/my-project/locations/my-region/keyRings/my-kr/cryptoKeys/my-key
. This value may not be changed after the Repository has been created.- Labels Dictionary<string, string>
Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.
- Location string
The name of the location this repository is located in.
- Maven
Config RepositoryMaven Config Args MavenRepositoryConfig is maven related repository details. Provides additional configuration details for repositories of the maven format type. Structure is documented below.
- Name string
The name of the repository, for example: "projects/p1/locations/us-central1/repositories/repo1"
- Project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- Repository
Id string The last part of the repository name, for example: "repo1"
- Update
Time string The time when the repository was last updated.
- Create
Time string The time when the repository was created.
- Description string
The user-provided description of the repository.
- Format string
The format of packages that are stored in the repository. Supported formats can be found here. You can only create alpha formats if you are a member of the alpha user group.
- Kms
Key stringName The Cloud KMS resource name of the customer managed encryption key that’s used to encrypt the contents of the Repository. Has the form:
projects/my-project/locations/my-region/keyRings/my-kr/cryptoKeys/my-key
. This value may not be changed after the Repository has been created.- Labels map[string]string
Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.
- Location string
The name of the location this repository is located in.
- Maven
Config RepositoryMaven Config Args MavenRepositoryConfig is maven related repository details. Provides additional configuration details for repositories of the maven format type. Structure is documented below.
- Name string
The name of the repository, for example: "projects/p1/locations/us-central1/repositories/repo1"
- Project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- Repository
Id string The last part of the repository name, for example: "repo1"
- Update
Time string The time when the repository was last updated.
- create
Time String The time when the repository was created.
- description String
The user-provided description of the repository.
- format String
The format of packages that are stored in the repository. Supported formats can be found here. You can only create alpha formats if you are a member of the alpha user group.
- kms
Key StringName The Cloud KMS resource name of the customer managed encryption key that’s used to encrypt the contents of the Repository. Has the form:
projects/my-project/locations/my-region/keyRings/my-kr/cryptoKeys/my-key
. This value may not be changed after the Repository has been created.- labels Map<String,String>
Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.
- location String
The name of the location this repository is located in.
- maven
Config RepositoryMaven Config Args MavenRepositoryConfig is maven related repository details. Provides additional configuration details for repositories of the maven format type. Structure is documented below.
- name String
The name of the repository, for example: "projects/p1/locations/us-central1/repositories/repo1"
- project String
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- repository
Id String The last part of the repository name, for example: "repo1"
- update
Time String The time when the repository was last updated.
- create
Time string The time when the repository was created.
- description string
The user-provided description of the repository.
- format string
The format of packages that are stored in the repository. Supported formats can be found here. You can only create alpha formats if you are a member of the alpha user group.
- kms
Key stringName The Cloud KMS resource name of the customer managed encryption key that’s used to encrypt the contents of the Repository. Has the form:
projects/my-project/locations/my-region/keyRings/my-kr/cryptoKeys/my-key
. This value may not be changed after the Repository has been created.- labels {[key: string]: string}
Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.
- location string
The name of the location this repository is located in.
- maven
Config RepositoryMaven Config Args MavenRepositoryConfig is maven related repository details. Provides additional configuration details for repositories of the maven format type. Structure is documented below.
- name string
The name of the repository, for example: "projects/p1/locations/us-central1/repositories/repo1"
- project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- repository
Id string The last part of the repository name, for example: "repo1"
- update
Time string The time when the repository was last updated.
- create_
time str The time when the repository was created.
- description str
The user-provided description of the repository.
- format str
The format of packages that are stored in the repository. Supported formats can be found here. You can only create alpha formats if you are a member of the alpha user group.
- kms_
key_ strname The Cloud KMS resource name of the customer managed encryption key that’s used to encrypt the contents of the Repository. Has the form:
projects/my-project/locations/my-region/keyRings/my-kr/cryptoKeys/my-key
. This value may not be changed after the Repository has been created.- labels Mapping[str, str]
Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.
- location str
The name of the location this repository is located in.
- maven_
config RepositoryMaven Config Args MavenRepositoryConfig is maven related repository details. Provides additional configuration details for repositories of the maven format type. Structure is documented below.
- name str
The name of the repository, for example: "projects/p1/locations/us-central1/repositories/repo1"
- project str
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- repository_
id str The last part of the repository name, for example: "repo1"
- update_
time str The time when the repository was last updated.
- create
Time String The time when the repository was created.
- description String
The user-provided description of the repository.
- format String
The format of packages that are stored in the repository. Supported formats can be found here. You can only create alpha formats if you are a member of the alpha user group.
- kms
Key StringName The Cloud KMS resource name of the customer managed encryption key that’s used to encrypt the contents of the Repository. Has the form:
projects/my-project/locations/my-region/keyRings/my-kr/cryptoKeys/my-key
. This value may not be changed after the Repository has been created.- labels Map<String>
Labels with user-defined metadata. This field may contain up to 64 entries. Label keys and values may be no longer than 63 characters. Label keys must begin with a lowercase letter and may only contain lowercase letters, numeric characters, underscores, and dashes.
- location String
The name of the location this repository is located in.
- maven
Config Property Map MavenRepositoryConfig is maven related repository details. Provides additional configuration details for repositories of the maven format type. Structure is documented below.
- name String
The name of the repository, for example: "projects/p1/locations/us-central1/repositories/repo1"
- project String
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- repository
Id String The last part of the repository name, for example: "repo1"
- update
Time String The time when the repository was last updated.
Supporting Types
RepositoryMavenConfig
- Allow
Snapshot boolOverwrites The repository with this flag will allow publishing the same snapshot versions.
- Version
Policy string Version policy defines the versions that the registry will accept. Default value is
VERSION_POLICY_UNSPECIFIED
. Possible values areVERSION_POLICY_UNSPECIFIED
,RELEASE
, andSNAPSHOT
.
- Allow
Snapshot boolOverwrites The repository with this flag will allow publishing the same snapshot versions.
- Version
Policy string Version policy defines the versions that the registry will accept. Default value is
VERSION_POLICY_UNSPECIFIED
. Possible values areVERSION_POLICY_UNSPECIFIED
,RELEASE
, andSNAPSHOT
.
- allow
Snapshot BooleanOverwrites The repository with this flag will allow publishing the same snapshot versions.
- version
Policy String Version policy defines the versions that the registry will accept. Default value is
VERSION_POLICY_UNSPECIFIED
. Possible values areVERSION_POLICY_UNSPECIFIED
,RELEASE
, andSNAPSHOT
.
- allow
Snapshot booleanOverwrites The repository with this flag will allow publishing the same snapshot versions.
- version
Policy string Version policy defines the versions that the registry will accept. Default value is
VERSION_POLICY_UNSPECIFIED
. Possible values areVERSION_POLICY_UNSPECIFIED
,RELEASE
, andSNAPSHOT
.
- allow_
snapshot_ booloverwrites The repository with this flag will allow publishing the same snapshot versions.
- version_
policy str Version policy defines the versions that the registry will accept. Default value is
VERSION_POLICY_UNSPECIFIED
. Possible values areVERSION_POLICY_UNSPECIFIED
,RELEASE
, andSNAPSHOT
.
- allow
Snapshot BooleanOverwrites The repository with this flag will allow publishing the same snapshot versions.
- version
Policy String Version policy defines the versions that the registry will accept. Default value is
VERSION_POLICY_UNSPECIFIED
. Possible values areVERSION_POLICY_UNSPECIFIED
,RELEASE
, andSNAPSHOT
.
Import
Repository can be imported using any of these accepted formats
$ pulumi import gcp:artifactregistry/repository:Repository default projects/{{project}}/locations/{{location}}/repositories/{{repository_id}}
$ pulumi import gcp:artifactregistry/repository:Repository default {{project}}/{{location}}/{{repository_id}}
$ pulumi import gcp:artifactregistry/repository:Repository default {{location}}/{{repository_id}}
$ pulumi import gcp:artifactregistry/repository:Repository default {{repository_id}}
Package Details
- Repository
- Google Cloud (GCP) Classic pulumi/pulumi-gcp
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
google-beta
Terraform Provider.