【发布时间】:2021-10-25 13:23:47
【问题描述】:
我是 m1 macbook 的新手,在运行 docker-compose 时遇到问题,如下所示:
version: "3.7"
services:
search:
platform: linux/x86_64
build:
context: .
dockerfile: Dockerfile.kubectl
还有 Dockerfile:
FROM ubuntu:latest
RUN apt-get update && apt-get install -y apt-transport-https curl gnupg2 unzip
RUN curl -s https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add -
RUN echo "deb https://apt.kubernetes.io/ kubernetes-xenial main" | tee -a /etc/apt/sources.list.d/kubernetes.list
RUN apt-get update && apt-get install -y kubectl
RUN curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" && unzip awscliv2.zip && rm awscliv2.zip
RUN ./aws/install
运行后出现这样的错误:
2021-09-30T13:24:52.816038712Z /lib64/ld-linux-x86-64.so.2: No such file or directory
解决此问题的具体步骤是什么?我的 Docker 版本是 4.1.1
【问题讨论】:
-
你的物理硬件不是
x86_64;你为什么要设置错误的架构? -
@DavidMaze 建议顺便回答一下这个问题。我正在为 m1 拱门寻求正确的方法
标签: docker docker-compose apple-m1