'Copy image to localstack ECR

I created ECR in localstack and I could see the created repository:

    qhuser@localstack:~$ awslocal ecr describe-repositories
{
    "repositories": [
        {
            "repositoryArn": "arn:aws:ecr:us-east-1:000000000000:repository/lstackrepo",
            "registryId": "9c6bfd5e",
            "repositoryName": "lstackrepo",
            "repositoryUri": "localhost:4510/lstackrepo",
            "createdAt": "2022-04-06T18:34:16+05:30",
            "imageTagMutability": "MUTABLE",
            "imageScanningConfiguration": {
                "scanOnPush": false
            },
            "encryptionConfiguration": {
                "encryptionType": "AES256"
            }
        }
    ]
}

I could do docker push to the created repository as below and I see the image is pushed and digest created.

docker image push localhost:4510/lstackrepo/xxxx:latest

But awslocal ecr list-images --repository-name lstackrepo/xxxx is not retrieving any image ids.

Am I missing anything here?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source