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

pluto: add regional map of pause container source accounts #1142

Merged
merged 1 commit into from
Oct 5, 2020

Conversation

tjkirch
Copy link
Contributor

@tjkirch tjkirch commented Oct 3, 2020

This allows us to handle regions where EKS keeps the container in a different account.


The map code is based on Matt's work in schnauzer.

Testing done:

test test_pause_container_account::url_af_south_1 ... ok
test test_pause_container_account::url_fallback ... ok
test test_pause_container_account::url_eu_west_1 ... ok

Made an AMI, ran a pod in us-west-2 OK, and ran a pod in af-south-1 OK.

Before, I saw this in af-south-1, and the instance didn't register with EKS: (the end got snipped, sorry)

not authorized to perform: ecr:BatchGetImage on resource: arn:aws:ecr:af-south-1:602401143452:repository/eks/pause-amd64

After, the pause container pulls OK (and the instance worked with EKS):

level=info msg="Pulled successfully" img="ecr.aws/arn:aws:ecr:af-south-1:877085696533:repository/eks/pause-amd64:3.1"

Terms of contribution:

By submitting this pull request, I agree that this contribution is dual-licensed under the terms of both the Apache License, version 2.0, and the MIT license.

This allows us to handle regions where EKS keeps the container in a different account.
Copy link
Contributor

@webern webern left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.

Copy link
Contributor

@zmrow zmrow left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👻

@tjkirch tjkirch merged commit 741750a into bottlerocket-os:develop Oct 5, 2020
@tjkirch tjkirch deleted the pluto-regions branch October 5, 2020 16:32
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

Successfully merging this pull request may close these issues.

5 participants