123456789101112131415161718192021222324252627282930313233343536373839 |
- # Copyright 2021 EMQ Technologies Co., Ltd.
- #
- # Licensed under the Apache License, Version 2.0 (the "License");
- # you may not use this file except in compliance with the License.
- # You may obtain a copy of the License at
- #
- # http://www.apache.org/licenses/LICENSE-2.0
- #
- # Unless required by applicable law or agreed to in writing, software
- # distributed under the License is distributed on an "AS IS" BASIS,
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- # See the License for the specific language governing permissions and
- # limitations under the License.
- FROM debian:bullseye
- ARG GO_VERSION
- ARG DEBIAN_FRONTEND="noninteractive"
- RUN apt-get update \
- && apt-get install -y make wget git curl procps zip libucl-dev zlib1g-dev \
- pkg-config libczmq-dev build-essential debhelper jq zip
- RUN case $(dpkg --print-architecture) in \
- arm|armhf|armv7) \
- ARCH=armv6l \
- ;; \
- *) \
- ARCH=$(dpkg --print-architecture)\
- ;; \
- esac \
- && wget --no-verbose https://golang.org/dl/go$GO_VERSION.linux-$ARCH.tar.gz \
- && tar -C /usr/local -xzf go$GO_VERSION.linux-$ARCH.tar.gz
- ENV PATH=$PATH:/usr/local/go/bin
- RUN wget --no-verbose https://github.com/upx/upx/releases/download/v3.96/upx-3.96-src.tar.xz -O - | tar -xvJC /usr/local \
- && cd /usr/local/upx-3.96-src && make all \
- && ln -s /usr/local/upx-3.96-src/src/upx.out /usr/bin/upx
|