summaryrefslogtreecommitdiff
path: root/build-vm-docker
diff options
context:
space:
mode:
authorshuai.fu <shuai01.fu@samsung.com>2017-07-11 18:19:17 +0900
committershuai.fu <shuai01.fu@samsung.com>2017-07-11 18:19:17 +0900
commite7cf1a72fcd5fec3fa316866a91bae688afe092e (patch)
tree993a2d585078e43e39ec9acbbb58b5295ff73e5b /build-vm-docker
parent928a3ba534cd87a97c6c627126f119d8a46ec932 (diff)
downloadbuild-e7cf1a72fcd5fec3fa316866a91bae688afe092e.tar.gz
build-e7cf1a72fcd5fec3fa316866a91bae688afe092e.tar.bz2
build-e7cf1a72fcd5fec3fa316866a91bae688afe092e.zip
modify vm_startup_docker
Change-Id: I8efa44d576e0e209120726c538280aa47eb53a02 Signed-off-by: shuai.fu <shuai01.fu@samsung.com>
Diffstat (limited to 'build-vm-docker')
-rw-r--r--build-vm-docker3
1 files changed, 2 insertions, 1 deletions
diff --git a/build-vm-docker b/build-vm-docker
index cd1558d..5e8e2d5 100644
--- a/build-vm-docker
+++ b/build-vm-docker
@@ -29,13 +29,14 @@ vm_verify_options_docker() {
vm_startup_docker() {
local name="obsbuild.${BUILD_ROOT##*/}"
+ local vm_init_script_docker="/.build/build"
local docker_server=`cat /etc/hosts | grep docker | cut -f 1`
local docker_port=`cat /etc/hosts | grep docker | cut -f 2`
docker_port=${docker_port#docker}
docker -H $docker_server:$docker_port rm --privileged "$name" >/dev/null 2>&1 || true
docker -H $docker_server:$docker_port run --privileged\
--rm --name "$name" --cap-add=sys_admin --net=none \
- -v "$BUILD_ROOT:/mnt" busybox /bin/chroot /mnt "$vm_init_script"
+ -v "$BUILD_ROOT:/mnt" busybox /bin/chroot /mnt "$vm_init_script_docker"
BUILDSTATUS="$?"
test "$BUILDSTATUS" != 255 || BUILDSTATUS=3
cleanup_and_exit "$BUILDSTATUS"