diff --git a/packages/virtualbox_cpi/packaging b/packages/virtualbox_cpi/packaging index 72be9b7c..70dda299 100644 --- a/packages/virtualbox_cpi/packaging +++ b/packages/virtualbox_cpi/packaging @@ -1,19 +1,19 @@ set -e -x +current_os=$(uname -s | tr '[:upper:]' '[:lower:]') if [ -z "$BOSH_PACKAGES_DIR" ]; then - pkg_dir=$(readlink -nf /var/vcap/packages/golang-1-darwin) + pkg_dir=$(readlink -nf /var/vcap/packages/golang-1-${current_os}) else - pkg_dir=$BOSH_PACKAGES_DIR/golang-1-darwin + pkg_dir=$BOSH_PACKAGES_DIR/golang-1-${current_os} fi -source ${pkg_dir}/bosh/compile.env.generic +source ${pkg_dir}/bosh/compile.env # Since HOME is not set we must set GOPATH and GOCACHE mkdir -p /tmp/go/.cache export GOPATH=/tmp/go export GOCACHE=${GOPATH}/.cache - cd ${BOSH_COMPILE_TARGET}/bosh-virtualbox-cpi mkdir -p ${BOSH_INSTALL_TARGET}/bin