disassociate_repositories
¶
disassociate_repositories(
repository_name: RepositoryName,
repository_type: RepositoryType,
associated_repository_name: RepositoryName,
associated_repository_type: RepositoryType,
*,
config_overrides: Optional[ECRPUBLICClientConfig] = None,
registry_id: Optional[RegistryId] = None,
) -> DisassociateRepositoriesResponse
Removes the association between two repositories in a public registry. One repository must be FREE and the other must be PREMIUM.
Parameters:
-
registry_id(Optional[RegistryId], default:None) –The Amazon Web Services account ID that's associated with the public registry that contains the repositories to disassociate. If you do not specify a registry, the default public registry is assumed. You can specify only your own account ID. Cross-account access through a repository policy isn't supported for this operation.
-
repository_name(RepositoryName) –The name of the source repository.
-
repository_type(RepositoryType) –The type of the source repository. Valid values:
-
FREE: A free repository. -
PREMIUM: A premium repository that holds paid content.
-
-
associated_repository_name(RepositoryName) –The name of the repository to disassociate from the source repository.
-
associated_repository_type(RepositoryType) –The type of the repository to disassociate from the source repository. Valid values:
-
FREE: A free repository. -
PREMIUM: A premium repository that holds paid content.
-
Raises:
-
AssociationNotFoundException–The specified repositories aren't associated. Check the repository names and types, and use
DescribePremiumRepositoriesorDescribeRepositoriesto check the current association. -
InvalidParameterException–The specified parameter is invalid. Review the available parameters for the API request.
-
LimitExceededException–The operation didn't succeed because it would have exceeded a service limit for your account. For more information, see Amazon ECR Public service quotas in the Amazon Elastic Container Registry Public User Guide.
-
RepositoryNotFoundException–The specified repository can't be found. Check the spelling of the specified repository and ensure that you're performing operations on the correct registry.
-
ServerException–These errors are usually caused by a server-side issue. Retry the request. If it continues to fail, contact Amazon Web Services Support.
-
UnsupportedCommandException–The action isn't supported in this Region. Check that the action is available in the Amazon Web Services Region that you're using, and try again in a supported Region.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
To disassociate a free repository from a premium repository This example removes the association between the premium repository my-premium-repository and the free repository my-free-repository.
>>> client.disassociate_repositories(repository_name='my-premium-repository', repository_type='PREMIUM', associated_repository_name='my-free-repository', associated_repository_type='FREE')
Source code in docs_src/capo_ecr_public/_services/ecrpublic.py
1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 | |