OpenApiImageCache
An ECI Image Cache can help user to solve the time-consuming problem of image pull. For information about Alicloud ECI Image Cache and how to use it, see What is Resource Alicloud ECI Image Cache.
NOTE: Available in v1.89.0+.
NOTE: Each image cache corresponds to a snapshot, and the user does not delete the snapshot directly, otherwise the cache will fail.
Create a OpenApiImageCache Resource
new OpenApiImageCache(name: string, args: OpenApiImageCacheArgs, opts?: CustomResourceOptions);def OpenApiImageCache(resource_name, opts=None, eip_instance_id=None, image_cache_name=None, image_cache_size=None, image_registry_credentials=None, images=None, resource_group_id=None, retention_days=None, security_group_id=None, vswitch_id=None, zone_id=None, __props__=None);func NewOpenApiImageCache(ctx *Context, name string, args OpenApiImageCacheArgs, opts ...ResourceOption) (*OpenApiImageCache, error)public OpenApiImageCache(string name, OpenApiImageCacheArgs args, CustomResourceOptions? opts = null)- name string
- The unique name of the resource.
- args OpenApiImageCacheArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- opts ResourceOptions
- A bag of options that control this resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args OpenApiImageCacheArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args OpenApiImageCacheArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
OpenApiImageCache Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.
Inputs
The OpenApiImageCache resource accepts the following input properties:
- Image
Cache stringName The name of the image cache.
- Images List<string>
The images to be cached. The image name must be versioned.
- Security
Group stringId The ID of the security group. You do not need to specify the same security group as the container group.
- Vswitch
Id string The ID of the VSwitch. You do not need to specify the same VSwitch as the container group.
- Eip
Instance stringId The instance ID of the Elastic IP Address (EIP). If you want to pull images from the Internet, you must specify an EIP to make sure that the container group can access the Internet. You can also configure the network address translation (NAT) gateway. We recommend that you configure the NAT gateway for the Internet access. Refer to Public Network Access Method
- Image
Cache intSize The size of the image cache. Default to
20. Unit: GiB.- Image
Registry List<Pulumi.Credentials Ali Cloud. Eci. Inputs. Open Api Image Cache Image Registry Credential Args> The Image Registry parameters about the image to be cached.
- Resource
Group stringId The ID of the resource group.
- Retention
Days int The retention days of the image cache. Once the image cache expires, it will be cleared. By default, the image cache never expires. Note: The image cache that fails to be created is retained for only one day.
- Zone
Id string The zone id to cache image.
- Image
Cache stringName The name of the image cache.
- Images []string
The images to be cached. The image name must be versioned.
- Security
Group stringId The ID of the security group. You do not need to specify the same security group as the container group.
- Vswitch
Id string The ID of the VSwitch. You do not need to specify the same VSwitch as the container group.
- Eip
Instance stringId The instance ID of the Elastic IP Address (EIP). If you want to pull images from the Internet, you must specify an EIP to make sure that the container group can access the Internet. You can also configure the network address translation (NAT) gateway. We recommend that you configure the NAT gateway for the Internet access. Refer to Public Network Access Method
- Image
Cache intSize The size of the image cache. Default to
20. Unit: GiB.- Image
Registry []OpenCredentials Api Image Cache Image Registry Credential The Image Registry parameters about the image to be cached.
- Resource
Group stringId The ID of the resource group.
- Retention
Days int The retention days of the image cache. Once the image cache expires, it will be cleared. By default, the image cache never expires. Note: The image cache that fails to be created is retained for only one day.
- Zone
Id string The zone id to cache image.
- image
Cache stringName The name of the image cache.
- images string[]
The images to be cached. The image name must be versioned.
- security
Group stringId The ID of the security group. You do not need to specify the same security group as the container group.
- vswitch
Id string The ID of the VSwitch. You do not need to specify the same VSwitch as the container group.
- eip
Instance stringId The instance ID of the Elastic IP Address (EIP). If you want to pull images from the Internet, you must specify an EIP to make sure that the container group can access the Internet. You can also configure the network address translation (NAT) gateway. We recommend that you configure the NAT gateway for the Internet access. Refer to Public Network Access Method
- image
Cache numberSize The size of the image cache. Default to
20. Unit: GiB.- image
Registry OpenCredentials Api Image Cache Image Registry Credential[] The Image Registry parameters about the image to be cached.
- resource
Group stringId The ID of the resource group.
- retention
Days number The retention days of the image cache. Once the image cache expires, it will be cleared. By default, the image cache never expires. Note: The image cache that fails to be created is retained for only one day.
- zone
Id string The zone id to cache image.
- image_
cache_ strname The name of the image cache.
- images List[str]
The images to be cached. The image name must be versioned.
- security_
group_ strid The ID of the security group. You do not need to specify the same security group as the container group.
- vswitch_
id str The ID of the VSwitch. You do not need to specify the same VSwitch as the container group.
- eip_
instance_ strid The instance ID of the Elastic IP Address (EIP). If you want to pull images from the Internet, you must specify an EIP to make sure that the container group can access the Internet. You can also configure the network address translation (NAT) gateway. We recommend that you configure the NAT gateway for the Internet access. Refer to Public Network Access Method
- image_
cache_ floatsize The size of the image cache. Default to
20. Unit: GiB.- image_
registry_ List[Opencredentials Api Image Cache Image Registry Credential] The Image Registry parameters about the image to be cached.
- resource_
group_ strid The ID of the resource group.
- retention_
days float The retention days of the image cache. Once the image cache expires, it will be cleared. By default, the image cache never expires. Note: The image cache that fails to be created is retained for only one day.
- zone_
id str The zone id to cache image.
Outputs
All input properties are implicitly available as output properties. Additionally, the OpenApiImageCache resource produces the following output properties:
Look up an Existing OpenApiImageCache Resource
Get an existing OpenApiImageCache 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?: OpenApiImageCacheState, opts?: CustomResourceOptions): OpenApiImageCachestatic get(resource_name, id, opts=None, container_group_id=None, eip_instance_id=None, image_cache_name=None, image_cache_size=None, image_registry_credentials=None, images=None, resource_group_id=None, retention_days=None, security_group_id=None, status=None, vswitch_id=None, zone_id=None, __props__=None);func GetOpenApiImageCache(ctx *Context, name string, id IDInput, state *OpenApiImageCacheState, opts ...ResourceOption) (*OpenApiImageCache, error)public static OpenApiImageCache Get(string name, Input<string> id, OpenApiImageCacheState? state, CustomResourceOptions? opts = null)- 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.
The following state arguments are supported:
- Container
Group stringId The ID of the container group job that is used to create the image cache. *
status-The status of the image cache.- Eip
Instance stringId The instance ID of the Elastic IP Address (EIP). If you want to pull images from the Internet, you must specify an EIP to make sure that the container group can access the Internet. You can also configure the network address translation (NAT) gateway. We recommend that you configure the NAT gateway for the Internet access. Refer to Public Network Access Method
- Image
Cache stringName The name of the image cache.
- Image
Cache intSize The size of the image cache. Default to
20. Unit: GiB.- Image
Registry List<Pulumi.Credentials Ali Cloud. Eci. Inputs. Open Api Image Cache Image Registry Credential Args> The Image Registry parameters about the image to be cached.
- Images List<string>
The images to be cached. The image name must be versioned.
- Resource
Group stringId The ID of the resource group.
- Retention
Days int The retention days of the image cache. Once the image cache expires, it will be cleared. By default, the image cache never expires. Note: The image cache that fails to be created is retained for only one day.
- Security
Group stringId The ID of the security group. You do not need to specify the same security group as the container group.
- Status string
- Vswitch
Id string The ID of the VSwitch. You do not need to specify the same VSwitch as the container group.
- Zone
Id string The zone id to cache image.
- Container
Group stringId The ID of the container group job that is used to create the image cache. *
status-The status of the image cache.- Eip
Instance stringId The instance ID of the Elastic IP Address (EIP). If you want to pull images from the Internet, you must specify an EIP to make sure that the container group can access the Internet. You can also configure the network address translation (NAT) gateway. We recommend that you configure the NAT gateway for the Internet access. Refer to Public Network Access Method
- Image
Cache stringName The name of the image cache.
- Image
Cache intSize The size of the image cache. Default to
20. Unit: GiB.- Image
Registry []OpenCredentials Api Image Cache Image Registry Credential The Image Registry parameters about the image to be cached.
- Images []string
The images to be cached. The image name must be versioned.
- Resource
Group stringId The ID of the resource group.
- Retention
Days int The retention days of the image cache. Once the image cache expires, it will be cleared. By default, the image cache never expires. Note: The image cache that fails to be created is retained for only one day.
- Security
Group stringId The ID of the security group. You do not need to specify the same security group as the container group.
- Status string
- Vswitch
Id string The ID of the VSwitch. You do not need to specify the same VSwitch as the container group.
- Zone
Id string The zone id to cache image.
- container
Group stringId The ID of the container group job that is used to create the image cache. *
status-The status of the image cache.- eip
Instance stringId The instance ID of the Elastic IP Address (EIP). If you want to pull images from the Internet, you must specify an EIP to make sure that the container group can access the Internet. You can also configure the network address translation (NAT) gateway. We recommend that you configure the NAT gateway for the Internet access. Refer to Public Network Access Method
- image
Cache stringName The name of the image cache.
- image
Cache numberSize The size of the image cache. Default to
20. Unit: GiB.- image
Registry OpenCredentials Api Image Cache Image Registry Credential[] The Image Registry parameters about the image to be cached.
- images string[]
The images to be cached. The image name must be versioned.
- resource
Group stringId The ID of the resource group.
- retention
Days number The retention days of the image cache. Once the image cache expires, it will be cleared. By default, the image cache never expires. Note: The image cache that fails to be created is retained for only one day.
- security
Group stringId The ID of the security group. You do not need to specify the same security group as the container group.
- status string
- vswitch
Id string The ID of the VSwitch. You do not need to specify the same VSwitch as the container group.
- zone
Id string The zone id to cache image.
- container_
group_ strid The ID of the container group job that is used to create the image cache. *
status-The status of the image cache.- eip_
instance_ strid The instance ID of the Elastic IP Address (EIP). If you want to pull images from the Internet, you must specify an EIP to make sure that the container group can access the Internet. You can also configure the network address translation (NAT) gateway. We recommend that you configure the NAT gateway for the Internet access. Refer to Public Network Access Method
- image_
cache_ strname The name of the image cache.
- image_
cache_ floatsize The size of the image cache. Default to
20. Unit: GiB.- image_
registry_ List[Opencredentials Api Image Cache Image Registry Credential] The Image Registry parameters about the image to be cached.
- images List[str]
The images to be cached. The image name must be versioned.
- resource_
group_ strid The ID of the resource group.
- retention_
days float The retention days of the image cache. Once the image cache expires, it will be cleared. By default, the image cache never expires. Note: The image cache that fails to be created is retained for only one day.
- security_
group_ strid The ID of the security group. You do not need to specify the same security group as the container group.
- status str
- vswitch_
id str The ID of the VSwitch. You do not need to specify the same VSwitch as the container group.
- zone_
id str The zone id to cache image.
Supporting Types
OpenApiImageCacheImageRegistryCredential
Package Details
- Repository
- https://github.com/pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloudTerraform Provider.