An unrelated technical question: Currently I'm run...
# prefect-community
a
An unrelated technical question: Currently I'm running DockerAgent on an AWS EC2 server, and it's pulling flow images from an ECR. On that EC2, we need to run
$(aws ecr get-login --region redacted-region --registry-ids 1234567890 --no-include-email)
in order to generate an ECR docker authorization token, and login -- this is standard practice. However! This token is only valid for 12 hours, so the command above is re-run automatically. Now the weird thing is, Prefect Agent doesn't actually "refresh" the auth token and gives me an "Your authorization token has expired" error, even though the command above was run. The only thing that helps is re-starting the Agent, at which point it starts using the new token again. This seems to be some king of a bug, since the configuration of the docker server should not concern the Agent -- or am I missing out on some configuration? Thanks
j
I’m not too familiar with the entire process but I believe the ECR Credential Helper may be what you want https://github.com/awslabs/amazon-ecr-credential-helper “Credential Helper helps developers in a continuous development environment to automate the authentication process to ECR repositories without having to regenerate tokens every 12 hours.”
👍 2