mirror of https://github.com/milvus-io/milvus.git
enhance: [skip 2e2]add the option of host network mode into builder_gpu.sh file (#30573)
Signed-off-by: Sammy Huang <sammy.huang@zilliz.com>pull/30660/head
parent
99297ab81b
commit
cbfe344ecf
|
@ -5,6 +5,10 @@ set -euo pipefail
|
||||||
# Absolute path to the toplevel milvus directory.
|
# Absolute path to the toplevel milvus directory.
|
||||||
toplevel=$(dirname "$(cd "$(dirname "${0}")"; pwd)")
|
toplevel=$(dirname "$(cd "$(dirname "${0}")"; pwd)")
|
||||||
|
|
||||||
|
if [[ "$IS_NETWORK_MODE_HOST" == "true" ]]; then
|
||||||
|
sed -i '/gpubuilder:/,/^\s*$/s/image: \${IMAGE_REPO}\/milvus-env:gpu-\${OS_NAME}-\${GPU_DATE_VERSION}/&\n network_mode: "host"/' $toplevel/docker-compose.yml
|
||||||
|
fi
|
||||||
|
|
||||||
export OS_NAME="${OS_NAME:-ubuntu20.04}"
|
export OS_NAME="${OS_NAME:-ubuntu20.04}"
|
||||||
|
|
||||||
pushd "${toplevel}"
|
pushd "${toplevel}"
|
||||||
|
|
|
@ -34,7 +34,10 @@ pipeline {
|
||||||
container('main') {
|
container('main') {
|
||||||
script {
|
script {
|
||||||
sh './build/set_docker_mirror.sh'
|
sh './build/set_docker_mirror.sh'
|
||||||
sh "./build/builder_gpu.sh /bin/bash -c \"make gpu-install\""
|
sh """
|
||||||
|
export IS_NETWORK_MODE_HOST="true"
|
||||||
|
./build/builder_gpu.sh /bin/bash -c \"make gpu-install\"
|
||||||
|
"""
|
||||||
|
|
||||||
def date = sh(returnStdout: true, script: 'date +%Y%m%d').trim()
|
def date = sh(returnStdout: true, script: 'date +%Y%m%d').trim()
|
||||||
def gitShortCommit = sh(returnStdout: true, script: 'git rev-parse --short HEAD').trim()
|
def gitShortCommit = sh(returnStdout: true, script: 'git rev-parse --short HEAD').trim()
|
||||||
|
|
Loading…
Reference in New Issue