建立普罗米修斯权力

时间:2020-05-12 07:29:54

标签: makefile dockerfile prometheus multiarch ppc64le

尝试在ppc64le上创建Prometheus映像。 它在复制步骤(第7、8行)中显示错误

(附加Dockerfile)

ARG ARCH="ppc64le"
ARG OS="linux"
FROM quay.io/prometheus/busybox-${OS}-${ARCH}:latest
LABEL maintainer="The Prometheus Authors <prometheus-developers@googlegroups.com>"

ARG ARCH="ppc64le"
ARG OS="linux"
**COPY .build/${OS}-${ARCH}/prometheus        /bin/prometheus**
**COPY .build/${OS}-${ARCH}/promtool          /bin/promtool**
COPY documentation/examples/prometheus.yml  /etc/prometheus/prometheus.yml
COPY console_libraries/                     /usr/share/prometheus/console_libraries/
COPY consoles/                              /usr/share/prometheus/consoles/
COPY LICENSE                                /LICENSE
COPY NOTICE                                 /NOTICE
COPY npm_licenses.tar.bz2                   /npm_licenses.tar.bz2

RUN ln -s /usr/share/prometheus/console_libraries /usr/share/prometheus/consoles/ /etc/prometheus/
RUN mkdir -p /prometheus && \
    chown -R nobody:nogroup etc/prometheus /prometheus

USER       nobody
EXPOSE     9090
VOLUME     [ "/prometheus" ]
WORKDIR    /prometheus
ENTRYPOINT [ "/bin/prometheus" ]
CMD        [ "--config.file=/etc/prometheus/prometheus.yml", \
             "--storage.tsdb.path=/prometheus", \
             "--web.console.libraries=/usr/share/prometheus/console_libraries", \
             "--web.console.templates=/usr/share/prometheus/consoles" ]

执行make build后,不会创建此/.build目录。因此,我正在使用Makefile,以便在生成二进制文件后自动创建此目录。例如,创建一个包含执行自动化指令的脚本文件,并在Makefile中沿构建目标进行提及。 因此,我想在Makefile中创建一个文件夹.build/linux-ppc64le/{prometheus binary},以便在我进行构建时自动构建该文件夹。如何实现?

Makefile链接-https://github.com/prometheus/prometheus/blob/master/Makefile

0 个答案:

没有答案