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

"/bin/sh: yum: command not found" while implementing "howto-mutual-tls-file-provided" in the walkthroughs #512

Open
77-more opened this issue Nov 1, 2022 · 1 comment

Comments

@77-more
Copy link
Contributor

77-more commented Nov 1, 2022

Issue description: While implementing the walk through available at "howto-mutual-tls-file-provided" at step #3 I came across the below error.

/bin/sh: yum: command not found

I was able to work around this issue by using the below Dockerfile instead.

FROM public.ecr.aws/appmesh/aws-appmesh-envoy:v1.23.1.0-prod as envoy 
FROM public.ecr.aws/amazonlinux/amazonlinux:2

RUN yum update -y && \
    yum install -y jq curl unzip less && \
    curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" && \
    unzip awscliv2.zip && \
    ./aws/install && \
    rpm -e --nodeps unzip && \
    rm -rf awscliv2.zip ./aws/install && \
    yum clean all && \
    rm -rf /var/cache/yum

COPY --from=envoy /usr/bin/envoy /usr/bin/envoy
COPY --from=envoy /usr/bin/agent /usr/bin/agent
COPY --from=envoy /aws_appmesh_aggregate_stats.wasm /aws_appmesh_aggregate_stats.wasm

RUN mkdir /keys && chown 1337:1337 /keys 

ENV AWS_DEFAULT_REGION=us-west-2
COPY entryPoint.sh /bin/entryPoint.sh
CMD ["/bin/entryPoint.sh"]

The Dockerfile has to be updated in the walkthrough to include the line "FROM public.ecr.aws/amazonlinux/amazonlinux:2" so that the yum commands will work.

@suniltheta
Copy link
Contributor

suniltheta commented Nov 1, 2022

Thanks for noticing this. Please feel free to raise a PR if you got the walkthrough working with the necessary changes needed.

Update: Ignore below

Also we might have to update the entrypoint commend from

CMD ["/bin/entryPoint.sh"]

to

CMD ["/usr/bin/agent"]

since the version v1.21

77-more added a commit to 77-more/aws-app-mesh-examples that referenced this issue Nov 8, 2022
Updating the Dockerfile to include the al2 image, otherwise building the docker image using this Dockerfile is going to give yum not found messages as discussed here aws#512.
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