File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ pipeline:
1212- name : publish-linux
1313 image : bash
1414 commands :
15- - CODENAME=bullseye ./build.sh all $CI_COMMIT_TAG
15+ - CODENAME=bookworm ./build.sh all $CI_COMMIT_TAG
1616 secrets :
1717 - oss_endpoint
1818 - oss_access_key_id
Original file line number Diff line number Diff line change @@ -57,12 +57,16 @@ RUN install-packages \
5757 unzip \
5858 xz-utils \
5959 zlib1g-dev \
60- python3-pip \
60+ python3-venv \
6161 libucl-dev \
6262 default-libmysqlclient-dev; \
63- pip install oss2
64- # build upx
65- RUN git clone -b v3.96 https://github.com/upx/upx --depth=1; \
66- cd upx; git submodule update --init --recursive; make all UPX_UCLDIR=../ucl-1.03 CXXFLAGS_OPTIMIZE="-no-pie -O2" ; cd -; \
67- cp upx/src/upx.out /usr/local/bin/upx; \
68- rm -rf ucl-1.03 ucl-1.03.tar.gz upx;
63+ python3 -m venv /usr/local/python
64+
65+ ENV PATH "/usr/local/python/bin:${PATH}"
66+
67+ RUN UPX_VERSION=4.0.2; \
68+ OS_ARCH=$(dpkg --print-architecture); \
69+ wget https://github.com/upx/upx/releases/download/v${UPX_VERSION}/upx-${UPX_VERSION}-${OS_ARCH}_linux.tar.xz; \
70+ tar -Jxvf upx-${UPX_VERSION}-${OS_ARCH}_linux.tar.xz; \
71+ cp upx-${UPX_VERSION}-${OS_ARCH}_linux/upx /usr/local/bin; \
72+ pip install oss2;
Original file line number Diff line number Diff line change @@ -5,6 +5,8 @@ shopt -s expand_aliases
55alias gzip=" gzip -n -9"
66
77. /etc/os-release
8+ export GO_VERSION=1.20
9+ export RUBY_VERSION=3.2
810export STACK_NAME=" ${STACK_NAME:? name is required} "
911export STACK_VERSION=" ${STACK_VERSION:? version is required} "
1012export OS_NAME=" ${OS_NAME:- linux} "
Original file line number Diff line number Diff line change 66# Implement build function
77function build() {
88 generate-stack-path
9- install-stack go 1.19.3 && . init-stack
9+ install-stack go " ${GO_VERSION} " && . init-stack
1010
1111 curl -sSL " https://github.com/subfuzion/envtpl/archive/refs/tags/v${STACK_VERSION} .tar.gz" | tar -xz \
1212 && mv envtpl-${STACK_VERSION} $GOPATH /src/envtpl/ \
Original file line number Diff line number Diff line change @@ -3,11 +3,11 @@ REBAR3_VERSION=$(curl -Ls https://github.com/erlang/rebar3/releases|grep /erlang
33
44set -xe \
55 && OTP_DOWNLOAD_URL=" https://github.com/erlang/otp/archive/OTP-${OTP_VERSION} .tar.gz" \
6- && runtimeDeps=' libodbc1 libsctp1 libwxgtk3.0 ' \
7- && buildDeps=' unixodbc-dev libsctp-dev libwxgtk-webview3.0-gtk3 -dev' \
6+ && runtimeDeps=' libodbc1 libsctp1 libwxgtk[0-9.-]{1,} libwxgtk-webview[0-9.-]{1,} ' \
7+ && buildDeps=' unixodbc-dev libsctp-dev libwxgtk-webview[0-9.-]{1,} -dev' \
88 && apt-get update \
9- && apt-get install -y --no-install-recommends $runtimeDeps \
10- && apt-get install -y --no-install-recommends $buildDeps \
9+ && echo apt-get install -y --no-install-recommends $runtimeDeps \
10+ && echo apt-get install -y --no-install-recommends $buildDeps \
1111 && curl -fSL -o otp-src.tar.gz " $OTP_DOWNLOAD_URL " \
1212 && export ERL_TOP=" /usr/src/otp_src_${OTP_VERSION%%@* } " \
1313 && mkdir -vp $ERL_TOP \
Original file line number Diff line number Diff line change 1- install-stack ruby 3.1.0
1+ install-stack ruby " ${RUBY_VERSION} "
22. /opt/drycc/ruby/profile.d/* .sh
33
4+ jemalloc_version=$( curl -Ls https://github.com/jemalloc/jemalloc/releases| grep /jemalloc/jemalloc/releases/tag/ | sed -E ' s/.*\/jemalloc\/jemalloc\/releases\/tag\/([0-9\.]{1,})".*/\1/g' | head -1)
45
56apt-get update \
67 && apt-get install -y --no-install-recommends \
@@ -11,12 +12,12 @@ apt-get update \
1112 " \
1213 && apt-get install -y --no-install-recommends $buildDeps \
1314 && echo ' gem: --no-document' >> /etc/gemrc \
14- && gem install oj -v 3.10.18 \
15- && gem install json -v 2.4.1 \
16- && gem install async-http -v 0.54.0 \
17- && gem install fluentd -v 1.14.5 \
18- && wget -O /tmp/jemalloc-4.5.0. tar.bz2 https://github.com/jemalloc/jemalloc/releases/download/4.5.0 /jemalloc-4.5.0 .tar.bz2 \
19- && cd /tmp && tar -xjf jemalloc-4.5.0. tar.bz2 && cd jemalloc-4.5.0 / \
15+ && gem install oj \
16+ && gem install json \
17+ && gem install async-http \
18+ && gem install fluentd -v ${STACK_VERSION} \
19+ && wget -O /tmp/jemalloc-${jemalloc_version} . tar.bz2 https://github.com/jemalloc/jemalloc/releases/download/${jemalloc_version} /jemalloc-${jemalloc_version} .tar.bz2 \
20+ && cd /tmp && tar -xjf jemalloc-${jemalloc_version} . tar.bz2 && cd jemalloc-${jemalloc_version} / \
2021 && ./configure && make \
2122 && mkdir -p /opt/drycc/fluentd/lib \
2223 && mv lib/libjemalloc.so.2 /opt/drycc/fluentd/lib \
Original file line number Diff line number Diff line change 77function build() {
88 generate-stack-path
99 install-packages make
10- install-stack go 1.19.3 && . init-stack
10+ install-stack go " ${GO_VERSION} " && . init-stack
1111
1212 curl -sSL " https://github.com/kubernetes/kube-state-metrics/archive/refs/tags/v${STACK_VERSION} .tar.gz" | tar -xz \
1313 && cd kube-state-metrics-${STACK_VERSION} \
@@ -23,4 +23,3 @@ function build() {
2323
2424# call build stack
2525build-stack " ${1} "
26-
Original file line number Diff line number Diff line change 77function build() {
88 generate-stack-path
99 install-packages make
10- install-stack go 1.19.3 && . init-stack
10+ install-stack go " ${GO_VERSION} " && . init-stack
1111
1212 curl -sSL " https://github.com/buildpacks/pack/archive/refs/tags/v${STACK_VERSION} .tar.gz" | tar -xz \
1313 && cd pack-${STACK_VERSION} \
Original file line number Diff line number Diff line change @@ -62,6 +62,7 @@ set -eux; \
6262 ; \
6363 tar -Jxf /usr/src/php.tar.xz -C /usr/src; \
6464 mv /usr/src/php-${STACK_VERSION} /usr/src/php; \
65+ cp -rf /usr/src/php /opt/drycc/php/src; \
6566 cd /usr/src/php; \
6667 gnuArch=" $( dpkg-architecture --query DEB_BUILD_GNU_TYPE) " ; \
6768 debMultiarch=" $( dpkg-architecture --query DEB_BUILD_MULTIARCH) " ; \
Original file line number Diff line number Diff line change 3737 go-md2man \
3838 libapparmor-dev
3939
40- install-stack go 1.19.3
40+ install-stack go " ${GO_VERSION} "
4141 export GOPATH=/opt/drycc/go
4242 export PATH=$GOPATH /bin:$PATH
4343
You can’t perform that action at this time.
0 commit comments