1 Star 0 Fork 0

shanke/mysql-docker

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
build.sh 1.86 KB
一键复制 编辑 原始数据 按行查看 历史
#!/bin/bash
# Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
set -e
source ./VERSION
if grep -q Microsoft /proc/version; then
echo "Running on Windows Subsystem for Linux"
# WSL doesn't have its own docker host, we have to use the one
# from Windows itself.
# https://medium.com/@sebagomez/installing-the-docker-client-on-ubuntus-windows-subsystem-for-linux-612b392a44c4
export DOCKER_HOST=localhost:2375
fi
ARCH=amd64; [ -n "$1" ] && ARCH=$1
MAJOR_VERSIONS=("${!MYSQL_SERVER_VERSIONS[@]}"); [ -n "$2" ] && MAJOR_VERSIONS=("${@:2}")
for MAJOR_VERSION in "${MAJOR_VERSIONS[@]}"; do
for MULTIARCH_VERSION in ${MULTIARCH_VERSIONS}; do
if [[ "$MULTIARCH_VERSION" == "$MAJOR_VERSION" ]]; then
docker build --build-arg http_proxy="$http_proxy" --build-arg https_proxy="$http_proxy" --build-arg no_proxy="$no_proxy" -t mysql/mysql-server:"$MAJOR_VERSION"-$ARCH "$MAJOR_VERSION"
fi
done
for SINGLEARCH_VERSION in $SINGLEARCH_VERSIONS; do
if [[ "$SINGLEARCH_VERSION" == "$MAJOR_VERSION" ]]; then
docker build --build-arg http_proxy="$http_proxy" --build-arg https_proxy="$http_proxy" --build-arg no_proxy="$no_proxy" -t mysql/mysql-server:"$MAJOR_VERSION" "$MAJOR_VERSION"
fi
done
done
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/760374564/mysql-docker.git
git@gitee.com:760374564/mysql-docker.git
760374564
mysql-docker
mysql-docker
mysql-server

搜索帮助