Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to update docker registry secret? #471

Open
MikhailKravets opened this issue May 29, 2023 · 2 comments
Open

How to update docker registry secret? #471

MikhailKravets opened this issue May 29, 2023 · 2 comments

Comments

@MikhailKravets
Copy link

MikhailKravets commented May 29, 2023

Hello! I've found the next problem with the docker secrets.

Problem Description

I've updated my AWS ECR registry password. Now I recreate yatai-regcred secret in yatai namespace

kubectl create secret docker-registry yatai-regcred 
  --docker-server=${AWS_ACCOUNT}.dkr.ecr.${AWS_REGION}.amazonaws.com \
  --docker-username=AWS \
  --docker-password=$(aws ecr get-login-password) \
  --namespace=yatai

Then I go to Yatai Dashboard and create new Deployment. Somehow it resets yatai-regcred to the previous state with the old password.

Dashboard deployment prints the following error

[2023-05-29 13:44:54] [BentoDeployment] [g] [ReconcileError] Failed to reconcile BentoDeployment: BentoRequest yatai/iris-2--h-5-bxdyx-6-bgnmsaib is not available: check image xxx.dkr.ecr.eu-north-1.amazonaws.com/yatai-bentos:yatai.iris2.h5bxdyx6bgnmsaib exists: create docker registry client for https://xxx.dkr.ecr.eu-north-1.amazonaws.com: Get "https://xxx.dkr.ecr.eu-north-1.amazonaws.com/v2/": http: non-successful response (status=403 body="{\"errors\":[{\"code\":\"DENIED\",\"message\":\"Your authorization token has expired. Reauthenticate and try again.\"}]}\n")

I've also updated docker password in yatai-image-builder-env secret from yatai-image-builder.

Reinstallation of yatai-deployment and yatai-image-builder helps but it's not an answer :)

@yetone
Copy link
Member

yetone commented May 29, 2023

If you use the ECR as a container registry, you can only use it in this way:

image

Do not use the password as it has expired.

https://docs.bentoml.org/projects/yatai/en/latest/installation/yatai_image_builder.html#prepare-container-registry

@MikhailKravets
Copy link
Author

Thanks for the answer @yetone. Is it possible to use AWS ECR outside of Amazon EKS then?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants