I'm hoping to create a private CodeArtifact PyPI repo with an upstream that connects to the public PyPI repo. The private repo will store packages with a certain prefix.
Examples:
- foo.databases
- foo.logging
I want to avoid pulling the packages above from the public PyPI repo if a version is requested from the private repo is not available. Any package request with a foo prefix should be blocked from the upstream repo.
Per the repository policy docs...
The codeartifact:ReadFromRepository action can only be used on a repository resource. You cannot put a package's Amazon Resource Name (ARN) as a resource with codeartifact:ReadFromRepository as the action to allow read access to a subset of packages in a repository. A given principal can either read all the packages in a repository or none of them.
...I get the impression that this is not possible. Is there any way to make this work? Artifactory uses an include / exclude pattern to solve this. I was hoping for something similar in CodeArtifact.