-
Notifications
You must be signed in to change notification settings - Fork 110
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Add helmoci package type for resources and data sources
- Loading branch information
Showing
33 changed files
with
1,053 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
--- | ||
subcategory: "Federated Repositories" | ||
--- | ||
# Artifactory Federated Helm OCI Repository Data Source | ||
|
||
Retrieves a federated Helm OCI repository. | ||
|
||
## Example Usage | ||
|
||
```hcl | ||
data "artifactory_federated_helmoci_repository" "my-helmoci-federated" { | ||
key = "my-helmoci-federated" | ||
} | ||
``` | ||
|
||
## Argument Reference | ||
|
||
* `key` - (Required) the identity key of the repo. | ||
|
||
## Attribute Reference | ||
The following attributes are supported, along with the [list of attributes from the local Helm OCI repository](local_helmoci_repository.md): | ||
|
||
* `member` - The list of Federated members and must contain this repository URL (configured base URL | ||
`/artifactory/` + repo `key`). Note that each of the federated members will need to have a base URL set. | ||
Please follow the [instruction](https://www.jfrog.com/confluence/display/JFROG/Working+with+Federated+Repositories#WorkingwithFederatedRepositories-SettingUpaFederatedRepository) | ||
to set up Federated repositories correctly. | ||
* `url` - Full URL to ending with the repository name. | ||
* `enabled` - Represents the active state of the federated member. It is supported to change the enabled | ||
status of my own member. The config will be updated on the other federated members automatically. | ||
* `proxy` - Proxy key from Artifactory Proxies settings. | ||
* `disable_proxy` - When set to `true`, the proxy is disabled, and not returned in the API response body. If there is a default proxy set for the Artifactory instance, it will be ignored, too. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
--- | ||
subcategory: "Local Repositories" | ||
--- | ||
|
||
# Artifactory Local Helm OCI Repository Data Source | ||
|
||
Retrieves a local Helm OCI repository resource | ||
|
||
## Example Usage | ||
|
||
```hcl | ||
resource "artifactory_local_helmoci_repository" "my-helmoci-local" { | ||
key = "my-helmoci-local" | ||
} | ||
``` | ||
|
||
## Argument Reference | ||
|
||
The following argument is supported: | ||
|
||
* `key` - (Required) the identity key of the repo. | ||
|
||
## Attribute Reference | ||
|
||
The following attributes are supported, along with the [common list of attributes for the local repositories](local.md): | ||
|
||
* `tag_retention` - If greater than 1, overwritten tags will be saved by their digest, up to the set up number. | ||
* `max_unique_tags` - The maximum number of unique tags of a single Docker image to store in this repository. Once the number tags for an image exceeds this setting, older tags are removed. A value of 0 (default) indicates there is no limit. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
--- | ||
subcategory: "Remote Repositories" | ||
--- | ||
# Artifactory Remote Helm OCI Repository Data Source | ||
|
||
Retrieves a remote Helm OCI repository. | ||
|
||
## Example Usage | ||
|
||
```hcl | ||
data "artifactory_remote_helmoci_repository" "my-helmoci-remote" { | ||
key = "my-helmoci-remote" | ||
} | ||
``` | ||
|
||
## Argument Reference | ||
|
||
The following argument is supported: | ||
|
||
* `key` - (Required) the identity key of the repo. | ||
|
||
## Attribute Reference | ||
|
||
The following attributes are supported, along with the [common list of attributes for the remote repositories](../resources/remote.md): | ||
|
||
* `enable_token_authentication` - (Optional) Enable token (Bearer) based authentication. | ||
* `external_dependencies_enabled` - (Optional) Also known as 'Foreign Layers Caching' on the UI. | ||
* `external_dependencies_patterns` - (Optional) Optional include patterns to match external URLs. Ant-style path expressions are supported (*, **, ?). For example, specifying `**/github.com/**` will only allow downloading foreign layers from github.com host. Due to SDKv2 limitations, we can't set the default value for the list. This value `[**]` must be assigned to the attribute manually, if user don't specify any other non-default values. We don't want to make this attribute required, but it must be set to avoid the state drift on update. Note: Artifactory assigns `[**]` on update if HCL doesn't have the attribute set or the list is empty. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
--- | ||
subcategory: "Virtual Repositories" | ||
--- | ||
# Artifactory Virtual Helm OCI Repository Data Source | ||
|
||
Retrieves a virtual Helm OCI repository. | ||
|
||
## Example Usage | ||
|
||
```hcl | ||
data "artifactory_virtual_helmoci_repository" "my-helmoci-virtual" { | ||
key = "my-helmoci-virtual" | ||
} | ||
``` | ||
|
||
## Argument Reference | ||
|
||
The following argument is supported: | ||
|
||
* `key` - (Required) the identity key of the repo. | ||
|
||
## Attribute Reference | ||
|
||
The following attributes are supported, along with the [common list of arguments for the virtual repositories](../resources/virtual.md): | ||
|
||
* `resolve_oci_tags_by_timestamp` - (Optional) When enabled, in cases where the same OCI tag exists in two or more of the aggregated repositories, Artifactory will return the tag that has the latest timestamp. Default values is `false`. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
--- | ||
subcategory: "Federated Repositories" | ||
--- | ||
# Artifactory Federated Helm OCI Repository Resource | ||
|
||
Creates a federated Helm OCI repository. | ||
|
||
## Example Usage | ||
|
||
```hcl | ||
resource "artifactory_federated_helmoci_repository" "my-helmoci-federated" { | ||
key = "my-helmoci-federated" | ||
member { | ||
url = "http://tempurl.org/artifactory/my-helmoci-federated" | ||
enabled = true | ||
} | ||
member { | ||
url = "http://tempurl2.org/artifactory/my-helmoci-federated-2" | ||
enabled = true | ||
} | ||
} | ||
``` | ||
|
||
## Argument Reference | ||
|
||
The following attributes are supported, along with the [list of attributes from the local Helm OCI repository](local_helmoci_repository.md): | ||
|
||
* `key` - (Required) the identity key of the repo. | ||
* `member` - (Required) The list of Federated members and must contain this repository URL (configured base URL | ||
`/artifactory/` + repo `key`). Note that each of the federated members will need to have a base URL set. | ||
Please follow the [instruction](https://www.jfrog.com/confluence/display/JFROG/Working+with+Federated+Repositories#WorkingwithFederatedRepositories-SettingUpaFederatedRepository) | ||
to set up Federated repositories correctly. | ||
* `url` - (Required) Full URL to ending with the repository name. | ||
* `enabled` - (Required) Represents the active state of the federated member. It is supported to change the enabled status of my own member. The config will be updated on the other federated members automatically. | ||
* `cleanup_on_delete` - (Optional) Delete all federated members on `terraform destroy` if set to `true`. Default is `false`. This attribute is added to match Terrform logic, so all the resources, created by the provider, must be removed on cleanup. Artifactory's behavior for the federated repositories is different, all the federated repositories stay after the user deletes the initial federated repository. **Caution**: if set to `true` all the repositories in the federation will be deleted, including repositories on other Artifactory instances in the "Circle of trust". This operation can not be reversed. | ||
* `proxy` - (Optional) Proxy key from Artifactory Proxies settings. Default is empty field. Can't be set if `disable_proxy = true`. | ||
* `disable_proxy` - (Optional, Default: `false`) When set to `true`, the proxy is disabled, and not returned in the API response body. If there is a default proxy set for the Artifactory instance, it will be ignored, too. | ||
|
||
## Import | ||
|
||
Federated repositories can be imported using their name, e.g. | ||
|
||
``` | ||
$ terraform import artifactory_federated_helmoci_repository.my-helmoci-federated my-helmoci-federated | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
--- | ||
subcategory: "Local Repositories" | ||
--- | ||
# Artifactory Local Helm OCI Repository Resource | ||
|
||
Creates a local Helm OCI repository. | ||
|
||
Official documentation can be found [here](https://jfrog.com/help/r/jfrog-artifactory-documentation/helm-oci-repositories) | ||
|
||
## Example Usage | ||
|
||
```hcl | ||
resource "artifactory_local_helmoci_repository" "my-helmoci-local" { | ||
key = "my-helmoci-local" | ||
tag_retention = 3 | ||
max_unique_tags = 5 | ||
} | ||
``` | ||
|
||
## Argument Reference | ||
|
||
Arguments have a one to one mapping with the [JFrog API](https://www.jfrog.com/confluence/display/RTF/Repository+Configuration+JSON). | ||
The following arguments are supported, along with the [common list of arguments for the local repositories](local.md): | ||
|
||
* `key` - (Required) the identity key of the repo. | ||
* `tag_retention` - (Optional) If greater than 1, overwritten tags will be saved by their digest, up to the set up number. | ||
* `max_unique_tags` - (Optional) The maximum number of unique tags of a single OCI image to store in this | ||
repository. Once the number tags for an image exceeds this setting, older tags are removed. | ||
A value of 0 (default) indicates there is no limit. | ||
|
||
## Import | ||
|
||
Local repositories can be imported using their name, e.g. | ||
|
||
``` | ||
$ terraform import artifactory_local_helmoci_repository.my-helmoci-local my-helmoci-local | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
--- | ||
subcategory: "Remote Repositories" | ||
--- | ||
# Artifactory Remote Helm OCI Repository Resource | ||
|
||
Creates remote Helm OCI repository resource. | ||
|
||
Official documentation can be found [here](https://jfrog.com/help/r/jfrog-artifactory-documentation/helm-oci-repositories) | ||
|
||
## Example Usage | ||
|
||
```hcl | ||
resource "artifactory_remote_helmoci_repository" "my-helmoci-remote" { | ||
key = "my-helmoci-remote" | ||
external_dependencies_enabled = true | ||
external_dependencies_patterns = ["**/registry-1.docker.io/**"] | ||
enable_token_authentication = true | ||
url = "https://registry-1.docker.io/" | ||
} | ||
``` | ||
|
||
## Argument Reference | ||
|
||
Arguments have a one to one mapping with the [JFrog API](https://www.jfrog.com/confluence/display/RTF/Repository+Configuration+JSON). | ||
The following arguments are supported, along with the [common list of arguments for the remote repositories](remote.md): | ||
|
||
* `key` - (Required) A mandatory identifier for the repository that must be unique. It cannot begin with a number or contain spaces or special characters. | ||
* `description` - (Optional) | ||
* `notes` - (Optional) | ||
* `url` - (Required) This is a URL to the remote registry. Consider using HTTPS to ensure a secure connection. | ||
* `enable_token_authentication` - (Optional) Enable token (Bearer) based authentication. | ||
* `external_dependencies_enabled` - (Optional) Also known as 'Foreign Layers Caching' on the UI. | ||
* `external_dependencies_patterns` - (Optional) Optional include patterns to match external URLs. Ant-style path expressions are supported (*, **, ?). For example, specifying `**/github.com/**` will only allow downloading foreign layers from github.com host. By default, this is set to `**` in the UI, which means that foreign layers may be downloaded from any external hosts. Due to SDKv2 limitations, we can't set the default value for the list. This value `**` must be assigned to the attribute manually, if user don't specify any other non-default values. We don't want to make this attribute required, but it must be set to avoid the state drift on update. Note: Artifactory assigns `**` on update if HCL doesn't have the attribute set or the list is empty. | ||
* `project_id` (Optional) Use this attribute to enter your GCR, GAR Project Id to limit the scope of this remote repo to a specific project in your third-party registry. When leaving this field blank or unset, remote repositories that support project id will default to their default project as you have set up in your account. | ||
|
||
## Import | ||
|
||
Remote repositories can be imported using their name, e.g. | ||
|
||
``` | ||
$ terraform import artifactory_remote_helmoci_repository.my-helmoci-remote my-helmoci-remote | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
--- | ||
subcategory: "Virtual Repositories" | ||
--- | ||
# Artifactory Virtual Helm OCI Repository Resource | ||
|
||
Creates a virtual Helm OCI repository. | ||
|
||
Official documentation can be found [here](https://jfrog.com/help/r/jfrog-artifactory-documentation/helm-oci-repositories). | ||
|
||
## Example Usage | ||
|
||
```hcl | ||
resource "artifactory_virtual_helmoci_repository" "my-helmoci-virtual" { | ||
key = "my-helmoci-virtual" | ||
repositories = [] | ||
description = "A test virtual repo" | ||
notes = "Internal description" | ||
includes_pattern = "com/jfrog/**,cloud/jfrog/**" | ||
excludes_pattern = "com/google/**" | ||
resolve_oci_tags_by_timestamp = true | ||
} | ||
``` | ||
|
||
## Argument Reference | ||
|
||
Arguments have a one to one mapping with the [JFrog API](https://www.jfrog.com/confluence/display/RTF/Repository+Configuration+JSON). | ||
|
||
The following arguments are supported, along with the [common list of arguments for the virtual repositories](virtual.md): | ||
|
||
* `key` - (Required) A mandatory identifier for the repository that must be unique. It cannot begin with a number or contain spaces or special characters. | ||
* `repositories` - (Optional) The effective list of actual repositories included in this virtual repository. | ||
* `description` - (Optional) | ||
* `notes` - (Optional) | ||
* `resolve_oci_tags_by_timestamp` - (Optional) When enabled, in cases where the same OCI tag exists in two or more of the aggregated repositories, Artifactory will return the tag that has the latest timestamp. Default values is `false`. | ||
|
||
## Import | ||
|
||
Virtual Helm OCI repositories can be imported using their name, e.g. | ||
|
||
``` | ||
$ terraform import artifactory_virtual_docker_repository.my-helmoci-virtual my-helmoci-virtual | ||
``` |
Oops, something went wrong.