Merge pull request #49 from jingjingxyk/fix_bug

修复 quckstart 脚本 bug
This commit is contained in:
Jerry Ma 2023-04-25 21:56:20 +08:00 committed by GitHub
commit ea055afd3c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 14 additions and 12 deletions

View File

@ -5,6 +5,8 @@ __DIR__=$(
cd "$(dirname "$0")"
pwd
)
cd ${__DIR__}
# use china mirror
# bash quickstart/linux/x86_64/alpine-3.16-init.sh --mirror china
@ -33,4 +35,4 @@ esac
apk update
apk add vim alpine-sdk xz autoconf automake linux-headers clang-dev clang lld libtool cmake bison re2c gettext coreutils
apk add vim alpine-sdk xz autoconf automake linux-headers clang-dev clang lld libtool cmake bison re2c gettext coreutils

View File

@ -8,4 +8,4 @@ __DIR__=$(
cd ${__DIR__}
docker exec -it static-php-cli-dev-1 bash
docker exec -it static-php-cli-dev-1 sh

View File

@ -5,9 +5,10 @@ __DIR__=$(
cd "$(dirname "$0")"
pwd
)
cd ${__DIR__}
# use china mirror
# bash quickstart/linux/x86_64/alpine-3.16-init.sh --mirror china
# bash quickstart/linux/x86_64/debian-11-init.sh --mirror china
mirror=''
while [ $# -gt 0 ]; do
case "$1" in
@ -24,19 +25,18 @@ done
case "$mirror" in
china)
test -f /etc/apk/repositories.save || cp /etc/apk/repositories /etc/apk/repositories.save
sed -i 's/dl-cdn.alpinelinux.org/mirrors.tuna.tsinghua.edu.cn/g' /etc/apk/repositories
test -f /etc/apt/sources.list.save || cp /etc/apt/sources.list /etc/apt/sources.list.save
sed -i "s@deb.debian.org@mirrors.ustc.edu.cn@g" /etc/apt/sources.list && \
sed -i "s@security.debian.org@mirrors.ustc.edu.cn@g" /etc/apt/sources.list
;;
esac
sed -i "s@deb.debian.org@mirrors.ustc.edu.cn@g" /etc/apt/sources.list && \
sed -i "s@security.debian.org@mirrors.ustc.edu.cn@g" /etc/apt/sources.list
apt update -y
apt install -y git curl wget ca-certificates
apt install -y xz-utils autoconf automake libclang-13-dev clang lld libtool cmake bison re2c gettext coreutils lzip zip unzip
apt install -y pkg-config bzip2 flex
apt install -y git curl wget ca-certificates
apt install -y xz-utils autoconf automake lld libtool cmake bison re2c gettext coreutils lzip zip unzip
apt install -y pkg-config bzip2 flex
apt install -y musl-tools g++
apt install -y clang
# apt install build-essential linux-headers-$(uname -r)