+SHELL:=/bin/bash
+BMDIR:=$(CURDIR)/env/metal3
+METAL3DIR:=$(CURDIR)/deploy/metal3/scripts
+all: bm_install
+
+bm_preinstall:
+ pushd $(BMDIR) && ./01_install_package.sh && ./02_configure.sh && ./03_launch_prereq.sh && popd
+
+bm_install:
+ pushd $(METAL3DIR) && ./metal3.sh && popd
+
+.PHONY: all bm_preinstall bm_install
source $LIBDIR/env/lib/common.sh
+if [[ $EUID -ne 0 ]]; then
+ echo "This script must be run as root"
+ exit 1
+fi
+
function get_default_inteface_ipaddress() {
local _ip=$1
local _default_interface=$(awk '$2 == 00000000 { print $1 }' /proc/net/route)
#!/usr/bin/env bash
set -ex
-lib/common.sh
-lib/logging.sh
+LIBDIR="$(dirname "$PWD")"
+
+source $LIBDIR/lib/common.sh
+source $LIBDIR/lib/logging.sh
if [[ $EUID -ne 0 ]]; then
echo "This script must be run as root"
#!/usr/bin/env bash
set -xe
+LIBDIR="$(dirname "$PWD")"
-source lib/logging.sh
-source lib/common.sh
+source $LIBDIR/lib/logging.sh
+source $LIBDIR/lib/common.sh
if [[ $EUID -ne 0 ]]; then
echo "confgiure script must be run as root"
#!/bin/bash
set -xe
-source lib/logging.sh
-source lib/common.sh
+LIBDIR="$(dirname "$PWD")"
+
+source $LIBDIR/lib/logging.sh
+source $LIBDIR/lib/common.sh
if [[ $EUID -ne 0 ]]; then
- echo "confgiure script must be run as root"
+ echo "launch script must be run as root"
exit 1
fi