1+ #
2+ # Copyright (c) 2024 Alibaba Group Holding Ltd.
3+ #
4+ # Licensed under the Apache License, Version 2.0 (the "License");
5+ # you may not use this file except in compliance with the License.
6+ # You may obtain a copy of the License at
7+ #
8+ # http://www.apache.org/licenses/LICENSE-2.0
9+ #
10+ # Unless required by applicable law or agreed to in writing, software
11+ # distributed under the License is distributed on an "AS IS" BASIS,
12+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+ # See the License for the specific language governing permissions and
14+ # limitations under the License.
15+ #
16+
17+
18+ # --------------
19+ # Stream edition
20+ # --------------
21+ FROM registry.cn-hangzhou.aliyuncs.com/alinux/aliyunlinux:aliyun_2_1903_x64_20G_alibase_20200904 AS stream
22+ USER root
23+ RUN echo pwd
24+
25+ RUN set -e
26+ RUN yum install -y tar \
27+ && cd /etc/ \
28+ && curl -L http://vvr-daily.oss-cn-hangzhou-zmf.aliyuncs.com/apt.tar.gz -o apt.tar.gz \
29+ && tar xf apt.tar.gz \
30+ && rm -rf apt.tar.gz \
31+ && cd /usr/lib/ \
32+ && curl -L http://yum.tbsite.net/taobao/8/x86_64/current/ajdk/ajdk-8.20.24-20230608121657.al8.x86_64.rpm -o ajdk-8.20.24-20230608121657.al8.x86_64.rpm \
33+ && rpm -ivh ajdk-8.20.24-20230608121657.al8.x86_64.rpm \
34+ && rm -f ajdk-8.20.24-20230608121657.al8.x86_64.rpm \
35+ && curl -L http://yum.tbsite.net/taobao/7/x86_64/current/ajdk11/ajdk11-11.0.22.22-20240417113200.alios7.x86_64.rpm -o ajdk11-11.0.22.22-20240417113200.alios7.x86_64.rpm \
36+ && rpm -ivh ajdk11-11.0.22.22-20240417113200.alios7.x86_64.rpm \
37+ && rm -f ajdk11-11.0.22.22-20240417113200.alios7.x86_64.rpm \
38+ && curl -L http://yum.tbsite.net/taobao/7/x86_64/current/ajdk17/ajdk17-17.0.5.0.5-20221117161857.alios7.x86_64.rpm -o ajdk17-17.0.5.0.5-20221117161857.alios7.x86_64.rpm \
39+ && rpm -ivh ajdk17-17.0.5.0.5-20221117161857.alios7.x86_64.rpm \
40+ && rm -f ajdk17-17.0.5.0.5-20221117161857.alios7.x86_64.rpm \
41+ && (yum install -y jemalloc-devel || yum install -y jemalloc-devel) \
42+ && rm -rf /var/cache/yum # retry because the installation of jemalloc-devel may fail
43+
44+ ENV JAVA_HOME=/opt/taobao/install/ajdk_8.20.24/
45+ ENV JAVA_HOME11=/opt/taobao/install/ajdk11_11.0.22.22/
46+ ENV JAVA_HOME17=/opt/taobao/install/ajdk17_17.0.5.0.5/
47+ ENV PATH=${JAVA_HOME17}/bin:$PATH
48+
49+ RUN sed -i "s/\/\/ .*deb.debian.org/\/\/ mirrors.aliyun.com/g;s/\/\/ .*security.debian.org/\/\/ mirrors.aliyun.com/g" /etc/apt/sources.list \
50+ && yum install -y tini \
51+ && yum install -y glibc-common \
52+ && yum install -y net-tools \
53+ && yum install -y telnet \
54+ && yum install -y wget \
55+ && yum install -y curl \
56+ && yum install -y apr-devel openssl-devel \
57+ && yum install -y procps \
58+ && yum install -y iputils \
59+ && yum install -y initscripts \
60+ && yum install -y crontabs \
61+ && cd / \
62+ && yum install -y mpfr-devel perf \
63+ && cd /opt/ \
64+ && wget https://native-resource.oss-cn-beijing.aliyuncs.com/native-tools_profiler-fix.tar.gz -O native-tools.tar.gz \
65+ && tar xf native-tools.tar.gz \
66+ && rm -rf native-tools.tar.gz \
67+ && cd /usr/local \
68+ && wget http://vvr-daily.oss-cn-hangzhou-zmf.aliyuncs.com/gcc.tar.gz \
69+ && tar xf gcc.tar.gz \
70+ && printf "/usr/local/gcc/lib64\n " > /etc/ld.so.conf.d/gcc10.conf \
71+ && ldconfig \
72+ && rm -rf gcc.tar.gz \
73+ && printf "\n kernel.perf_event_paranoid = -1\n kernel.yama.ptrace_scope = 0\n " >> /etc/sysctl.conf \
74+ && rm -rf /usr/lib/locale \
75+ && rm -rf /var/cache/yum
76+
77+ ENV PATH=/fluss/bin:$PATH
78+ COPY --chown=root:root build-target/ /fluss/
79+
80+ WORKDIR /fluss
81+ USER root
82+ CMD ["bash" ]
0 commit comments